Merge remote-tracking branch 'WD-core/master' into upstream-12

This commit is contained in:
BIGZi0348
2024-12-13 21:49:21 +03:00
10 changed files with 51 additions and 31 deletions

View File

@@ -1,4 +1,4 @@
using Content.Server.GameTicking;
using Content.Server.GameTicking;
using Content.Server.RoundEnd;
using Content.Server.Voting.Managers;
using Content.Shared.Voting;

View File

@@ -22,4 +22,18 @@ public sealed partial class MaskComponent : Component
[DataField, AutoNetworkedField]
public string EquippedPrefix = "toggled";
/// <summary>
/// WD Ahead of wizden.
/// When <see langword="true"/> will function normally, otherwise will not react to events
/// </summary>
[DataField("enabled"), AutoNetworkedField]
public bool IsEnabled = true;
/// <summary>
/// WD Ahead of wizden.
/// When <see langword="true"/> will disable <see cref="IsEnabled"/> when folded
/// </summary>
[DataField, AutoNetworkedField]
public bool DisableOnFolded;
}

View File

@@ -35,7 +35,7 @@ public sealed class MaskSystem : EntitySystem
private void OnToggleMask(Entity<MaskComponent> ent, ref ToggleMaskEvent args)
{
var (uid, mask) = ent;
if (mask.ToggleActionEntity == null || !_timing.IsFirstTimePredicted)
if (mask.ToggleActionEntity == null || !_timing.IsFirstTimePredicted || !mask.IsEnabled) // WD Ahead of wizden
return;
if (!_inventorySystem.TryGetSlotEntity(args.Performer, "mask", out var existing) || !uid.Equals(existing))
@@ -53,7 +53,7 @@ public sealed class MaskSystem : EntitySystem
// set to untoggled when unequipped, so it isn't left in a 'pulled down' state
private void OnGotUnequipped(EntityUid uid, MaskComponent mask, GotUnequippedEvent args)
{
if (!mask.IsToggled)
if (!mask.IsToggled || !mask.IsEnabled) // WD Ahead of wizden
return;
mask.IsToggled = false;
@@ -66,7 +66,7 @@ public sealed class MaskSystem : EntitySystem
private void ToggleMaskComponents(EntityUid uid, MaskComponent mask, EntityUid wearer, string? equippedPrefix = null, bool isEquip = false)
{
Dirty(uid, mask);
if (mask.ToggleActionEntity is {} action)
if (mask.ToggleActionEntity is { } action)
_actionSystem.SetToggled(action, mask.IsToggled);
var maskEv = new ItemMaskToggledEvent(wearer, equippedPrefix, mask.IsToggled, isEquip);
@@ -78,6 +78,8 @@ public sealed class MaskSystem : EntitySystem
private void OnFolded(Entity<MaskComponent> ent, ref FoldedEvent args)
{
if (ent.Comp.DisableOnFolded) // WD Ahead of wizden
ent.Comp.IsEnabled = !args.IsFolded;
ent.Comp.IsToggled = args.IsFolded;
ToggleMaskComponents(ent.Owner, ent.Comp, ent.Owner);

View File

@@ -1,26 +1,4 @@
Entries:
- author: RavMorgan
changes:
- message: "\u0414\u043E\u0431\u0430\u0432\u043B\u0435\u043D \u043F\u0430\u0438\
\ \u043D\u0430 \u043D\u0435\u0439\u0440\u043E\u0441\u0435\u0442\u044F\u0445!"
type: Add
id: 127
time: '2023-04-08T06:06:22.0000000+00:00'
- author: HitPanda
changes:
- message: "\u0421\u043A\u0430\u0444\u0430\u043D\u0434\u0440\u0443 \u0433\u043B\u0430\
\u0432\u044B \u0441\u043B\u0443\u0436\u0431\u044B \u0431\u0435\u0437\u043E\u043F\
\u0430\u0441\u043D\u043E\u0441\u0442\u0438 \u0432\u0435\u0440\u043D\u0443\u043B\
\u0438 \u043F\u0440\u0435\u0436\u043D\u044E\u044E \u0432\u0435\u0440\u0441\u0438\
\u044E, \u0435\u0433\u043E \u0442\u0435\u043A\u0443\u0449\u0430\u044F \u0432\
\u0435\u0440\u0441\u0438\u044F \u0437\u0430\u043C\u0435\u043D\u0438\u043B\u0430\
\ \u0441\u043A\u0430\u0444\u0430\u043D\u0434\u0440 \u0432\u0430\u0440\u0434\u0435\
\u043D\u0430, \u043A\u0430\u043A \u0438 \u0434\u043E\u043B\u0436\u043D\u043E\
\ \u0431\u044B\u043B\u043E \u0431\u044B\u0442\u044C \u0438\u0437\u043D\u0430\
\u0447\u0430\u043B\u044C\u043D\u043E."
type: Fix
id: 128
time: '2023-04-08T12:18:55.0000000+00:00'
- author: HitPanda
changes:
- message: "\u041F\u0435\u0440\u0435\u0432\u043E\u0434 \u0442\u0438\u043F\u043E\u0432\
@@ -8911,3 +8889,24 @@
id: 626
time: '2024-12-12T20:31:26.0000000+00:00'
url: https://api.github.com/repos/frosty-dev/ss14-core/pulls/817
- author: BIG_Zi_348
changes:
- message: "\u0418\u0441\u043F\u0440\u0430\u0432\u043B\u0435\u043D\u043E \u043D\u0435\
\u043A\u043E\u0440\u0440\u0435\u043A\u0442\u043D\u043E\u0435 \u043F\u043E\u0432\
\u0435\u0434\u0435\u043D\u0438\u0435 \u0431\u0430\u043D\u0434\u0430\u043D\u044B\
."
type: Fix
id: 627
time: '2024-12-13T18:18:04.0000000+00:00'
url: https://api.github.com/repos/frosty-dev/ss14-core/pulls/818
- author: BIG_Zi_348
changes:
- message: "\u0414\u043E\u0431\u0430\u0432\u043B\u0435\u043D\u043E \u0430\u0432\u0442\
\u043E\u043C\u0430\u0442\u0438\u0447\u0435\u0441\u043A\u043E\u0435 \u0433\u043E\
\u043B\u043E\u0441\u043E\u0432\u0430\u043D\u0438\u0435 \u0437\u0430 \u0432\u044B\
\u0431\u043E\u0440 \u0440\u0435\u0436\u0438\u043C\u0430 \u0438 \u043A\u0430\u0440\
\u0442\u044B."
type: Add
id: 628
time: '2024-12-13T18:43:45.0000000+00:00'
url: https://api.github.com/repos/frosty-dev/ss14-core/pulls/819

View File

@@ -7,6 +7,8 @@
folded: true
- type: Mask
isToggled: true
enabled: false
disableOnFolded: true
- type: IngestionBlocker
enabled: false
- type: IdentityBlocker
@@ -20,6 +22,8 @@
- state: icon_mask
map: [ "unfoldedLayer" ]
visible: false
- type: HideLayerClothing # needed since head bandana inherits from mask bandana
slots: []
- type: Tag
tags:
- Bandana

View File

@@ -12,6 +12,7 @@
unfoldedSlots:
- MASK
- type: Mask
disableOnFolded: true
- type: IngestionBlocker
- type: IdentityBlocker
coverage: MOUTH

View File

@@ -2,7 +2,7 @@
id: DryDock
mapName: 'DryDock Station'
mapPath: /Maps/_Honk/Stations/DryDock.yml
minPlayers: 0 # Amour
minPlayers: 0
stations:
DryDockStation:
stationProto: StandardNanotrasenStation

View File

@@ -2,7 +2,7 @@
id: WonderBox
mapName: 'WonderBox Station'
mapPath: /Maps/_Honk/Stations/WonderBox.yml
minPlayers: 0 # Amour
minPlayers: 0
stations:
WonderBoxStation:
stationProto: StandardNanotrasenStation

View File

@@ -2,7 +2,7 @@
id: Meta
mapName: 'Meta Station'
mapPath: /Maps/_Honk/Stations/Meta.yml
minPlayers: 0 # Amour
minPlayers: 0
stations:
Meta:
stationProto: StandardNanotrasenStation

View File

@@ -33,7 +33,7 @@
- extended
- shittersafari
name: extended-title
showInVote: true # Amour EDIT
showInVote: true # WD EDIT
description: extended-description
rules:
- BasicStationEventScheduler
@@ -46,7 +46,7 @@
- greenshift
- shittersafarideluxeedition
name: greenshift-title
showInVote: true # Amour EDIT
showInVote: true # WD EDIT
description: greenshift-description
rules:
- BasicRoundstartVariation