diff --git a/Content.Client/Overlays/ShowSyndicateIconsSystem.cs b/Content.Client/Overlays/ShowSyndicateIconsSystem.cs new file mode 100644 index 0000000000..25d4d9b895 --- /dev/null +++ b/Content.Client/Overlays/ShowSyndicateIconsSystem.cs @@ -0,0 +1,43 @@ +using Content.Shared.Overlays; +using Content.Shared.StatusIcon.Components; +using Content.Shared.NukeOps; +using Content.Shared.StatusIcon; +using Robust.Shared.Prototypes; + +namespace Content.Client.Overlays; +public sealed class ShowSyndicateIconsSystem : EquipmentHudSystem +{ + [Dependency] private readonly IPrototypeManager _prototype = default!; + + public override void Initialize() + { + base.Initialize(); + + SubscribeLocalEvent(OnGetStatusIconsEvent); + } + + private void OnGetStatusIconsEvent(EntityUid uid, NukeOperativeComponent nukeOperativeComponent, ref GetStatusIconsEvent args) + { + if (!IsActive || args.InContainer) + { + return; + } + + var healthIcons = SyndicateIcon(uid, nukeOperativeComponent); + + args.StatusIcons.AddRange(healthIcons); + } + + private IReadOnlyList SyndicateIcon(EntityUid uid, NukeOperativeComponent nukeOperativeComponent) + { + var result = new List(); + + if (_prototype.TryIndex(nukeOperativeComponent.SyndStatusIcon, out var syndicateicon)) + { + result.Add(syndicateicon); + } + + return result; + } +} + diff --git a/Content.Server/GameTicking/Rules/Components/NukeOperativeComponent.cs b/Content.Server/GameTicking/Rules/Components/NukeOperativeComponent.cs deleted file mode 100644 index 59fc9526dc..0000000000 --- a/Content.Server/GameTicking/Rules/Components/NukeOperativeComponent.cs +++ /dev/null @@ -1,16 +0,0 @@ -using Robust.Shared.Audio; - -namespace Content.Server.GameTicking.Rules.Components; - -/// -/// This is used for tagging a mob as a nuke operative. -/// -[RegisterComponent] -public sealed partial class NukeOperativeComponent : Component -{ - /// - /// Path to antagonist alert sound. - /// - [DataField("greetSoundNotification")] - public SoundSpecifier GreetSoundNotification = new SoundPathSpecifier("/Audio/Ambience/Antag/nukeops_start.ogg"); -} diff --git a/Content.Shared/Inventory/InventorySystem.Relay.cs b/Content.Shared/Inventory/InventorySystem.Relay.cs index fbe744911f..20a98dc124 100644 --- a/Content.Shared/Inventory/InventorySystem.Relay.cs +++ b/Content.Shared/Inventory/InventorySystem.Relay.cs @@ -42,6 +42,7 @@ public partial class InventorySystem SubscribeLocalEvent>(RelayInventoryEvent); SubscribeLocalEvent>(RelayInventoryEvent); SubscribeLocalEvent>(RelayInventoryEvent); + SubscribeLocalEvent>(RelayInventoryEvent); SubscribeLocalEvent>(OnGetEquipmentVerbs); } diff --git a/Content.Shared/NukeOps/NukeOperativeComponent.cs b/Content.Shared/NukeOps/NukeOperativeComponent.cs new file mode 100644 index 0000000000..cdbefece9d --- /dev/null +++ b/Content.Shared/NukeOps/NukeOperativeComponent.cs @@ -0,0 +1,27 @@ +using Robust.Shared.Audio; +using Content.Shared.StatusIcon; +using Robust.Shared.Prototypes; +using Robust.Shared.GameStates; +using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom; +using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototype; + +namespace Content.Shared.NukeOps; + +/// +/// This is used for tagging a mob as a nuke operative. +/// +[RegisterComponent, NetworkedComponent] +public sealed partial class NukeOperativeComponent : Component +{ + /// + /// Path to antagonist alert sound. + /// + [DataField("greetSoundNotification")] + public SoundSpecifier GreetSoundNotification = new SoundPathSpecifier("/Audio/Ambience/Antag/nukeops_start.ogg"); + + /// + /// + /// + [DataField("syndStatusIcon", customTypeSerializer: typeof(PrototypeIdSerializer))] + public string SyndStatusIcon = "SyndicateFaction"; +} diff --git a/Content.Shared/Overlays/ShowSyndicateIconsComponent.cs b/Content.Shared/Overlays/ShowSyndicateIconsComponent.cs new file mode 100644 index 0000000000..74a67db694 --- /dev/null +++ b/Content.Shared/Overlays/ShowSyndicateIconsComponent.cs @@ -0,0 +1,9 @@ +using Robust.Shared.GameStates; + +namespace Content.Shared.Overlays; + +/// +/// +/// +[RegisterComponent, NetworkedComponent] +public sealed partial class ShowSyndicateIconsComponent : Component {} diff --git a/Resources/Prototypes/Catalog/Fills/Lockers/misc.yml b/Resources/Prototypes/Catalog/Fills/Lockers/misc.yml index 9ed3acc049..64b173355d 100644 --- a/Resources/Prototypes/Catalog/Fills/Lockers/misc.yml +++ b/Resources/Prototypes/Catalog/Fills/Lockers/misc.yml @@ -11,6 +11,7 @@ - id: ClothingUniformJumpsuitOperative - id: ClothingUniformJumpskirtOperative - id: ClothingHeadsetAltSyndicate + - id: ClothingEyesHudSyndicate - type: entity id: ClosetEmergencyFilledRandom diff --git a/Resources/Prototypes/Entities/Clothing/Eyes/hud.yml b/Resources/Prototypes/Entities/Clothing/Eyes/hud.yml index 80317fbaec..dfd1e50a4b 100644 --- a/Resources/Prototypes/Entities/Clothing/Eyes/hud.yml +++ b/Resources/Prototypes/Entities/Clothing/Eyes/hud.yml @@ -129,6 +129,7 @@ - type: Clothing sprite: Clothing/Eyes/Hud/medsecengi.rsi - type: ShowSecurityIcons + - type: ShowSyndicateIcons - type: entity parent: ClothingEyesBase @@ -143,3 +144,18 @@ - type: ShowSecurityIcons - type: ShowHungerIcons - type: ShowThirstIcons + - type: ShowSyndicateIcons + +- type: entity + parent: ClothingEyesBase + id: ClothingEyesHudSyndicate + name: syndicate visor + description: The syndicate's professional head-up display, designed for better detection of humanoids and their subsequent elimination. + components: + - type: Sprite + sprite: Clothing/Eyes/Hud/synd.rsi + - type: Clothing + sprite: Clothing/Eyes/Hud/synd.rsi + - type: ShowSyndicateIcons + - type: ShowSecurityIcons + diff --git a/Resources/Prototypes/Roles/Jobs/Fun/misc_startinggear.yml b/Resources/Prototypes/Roles/Jobs/Fun/misc_startinggear.yml index ad99ef7def..8d53e0540f 100644 --- a/Resources/Prototypes/Roles/Jobs/Fun/misc_startinggear.yml +++ b/Resources/Prototypes/Roles/Jobs/Fun/misc_startinggear.yml @@ -103,8 +103,7 @@ jumpsuit: ClothingUniformJumpsuitOperative back: ClothingBackpackDuffelSyndicateOperative mask: ClothingMaskGasSyndicate - # eyes: Night Vision Goggles whenever they're made - eyes: ClothingEyesGlassesMeson + eyes: ClothingEyesHudSyndicate ears: ClothingHeadsetAltSyndicate gloves: ClothingHandsGlovesCombat outerClothing: ClothingOuterHardsuitSyndie @@ -124,8 +123,7 @@ jumpsuit: ClothingUniformJumpsuitOperative back: ClothingBackpackDuffelSyndicateOperative mask: ClothingMaskGasSyndicate - # eyes: Night Vision Goggles whenever they're made - eyes: ClothingEyesGlassesMeson + eyes: ClothingEyesHudSyndicate ears: ClothingHeadsetAltSyndicate gloves: ClothingHandsGlovesCombat outerClothing: ClothingOuterHardsuitSyndieCommander @@ -147,7 +145,7 @@ jumpsuit: ClothingUniformJumpsuitOperative back: ClothingBackpackDuffelSyndicateOperativeMedic mask: ClothingMaskGasSyndicate - eyes: ClothingEyesHudMedical + eyes: ClothingEyesHudSyndicate ears: ClothingHeadsetAltSyndicate gloves: ClothingHandsGlovesCombat outerClothing: ClothingOuterHardsuitMedic diff --git a/Resources/Prototypes/StatusIcon/antag.yml b/Resources/Prototypes/StatusIcon/antag.yml index 564d29a35b..6016d0c94e 100644 --- a/Resources/Prototypes/StatusIcon/antag.yml +++ b/Resources/Prototypes/StatusIcon/antag.yml @@ -18,3 +18,11 @@ icon: sprite: Interface/Misc/job_icons.rsi state: HeadRevolutionary + +- type: statusIcon + id: SyndicateFaction + priority: 0 + locationPreference: Left + icon: + sprite: Interface/Misc/job_icons.rsi + state: Syndicate diff --git a/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/equipped-EYES.png b/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/equipped-EYES.png new file mode 100644 index 0000000000..9128dd01f6 Binary files /dev/null and b/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/equipped-EYES.png differ diff --git a/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/icon.png b/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/icon.png new file mode 100644 index 0000000000..02dc6cc067 Binary files /dev/null and b/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/icon.png differ diff --git a/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/inhand-left.png b/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/inhand-left.png new file mode 100644 index 0000000000..ebd7858dab Binary files /dev/null and b/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/inhand-left.png differ diff --git a/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/inhand-right.png b/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/inhand-right.png new file mode 100644 index 0000000000..53535a1de7 Binary files /dev/null and b/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/inhand-right.png differ diff --git a/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/meta.json b/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/meta.json new file mode 100644 index 0000000000..e3bc1a2940 --- /dev/null +++ b/Resources/Textures/Clothing/Eyes/Hud/synd.rsi/meta.json @@ -0,0 +1,26 @@ +{ + "version": 1, + "license": "CC-BY-SA-3.0", + "copyright": "Made by IntegerTempest", + "size": { + "x": 32, + "y": 32 + }, + "states": [ + { + "name": "icon" + }, + { + "name": "equipped-EYES", + "directions": 4 + }, + { + "name": "inhand-left", + "directions": 4 + }, + { + "name": "inhand-right", + "directions": 4 + } + ] +} diff --git a/Resources/Textures/Interface/Misc/job_icons.rsi/Syndicate.png b/Resources/Textures/Interface/Misc/job_icons.rsi/Syndicate.png new file mode 100644 index 0000000000..a671977085 Binary files /dev/null and b/Resources/Textures/Interface/Misc/job_icons.rsi/Syndicate.png differ diff --git a/Resources/Textures/Interface/Misc/job_icons.rsi/meta.json b/Resources/Textures/Interface/Misc/job_icons.rsi/meta.json index 2d71fcd056..8a710b63ec 100644 --- a/Resources/Textures/Interface/Misc/job_icons.rsi/meta.json +++ b/Resources/Textures/Interface/Misc/job_icons.rsi/meta.json @@ -169,6 +169,9 @@ }, { "name": "HeadRevolutionary" + }, + { + "name": "Syndicate" } ] }