From 466992e6da194363a4b661d379981d9c54aefba1 Mon Sep 17 00:00:00 2001 From: Aviu00 Date: Thu, 18 Jan 2024 09:09:22 +0300 Subject: [PATCH] FIXXX --- .../GeneralStationRecordConsoleWindow.xaml.cs | 7 ++--- .../Body/Systems/RespiratorSystem.cs | 5 ++-- .../AntiCringeSystem/AntiCringeComponent.cs | 2 +- Content.Server/White/Other/OnDeath.cs | 3 ++- Resources/Prototypes/White/Actions/emotes.yml | 27 ++++++++++++------- .../Prototypes/White/Species/felinid.yml | 1 + 6 files changed, 29 insertions(+), 16 deletions(-) diff --git a/Content.Client/StationRecords/GeneralStationRecordConsoleWindow.xaml.cs b/Content.Client/StationRecords/GeneralStationRecordConsoleWindow.xaml.cs index 71f15f46d5..7ec0aa1a6a 100644 --- a/Content.Client/StationRecords/GeneralStationRecordConsoleWindow.xaml.cs +++ b/Content.Client/StationRecords/GeneralStationRecordConsoleWindow.xaml.cs @@ -1,4 +1,5 @@ using System.Linq; +using System.Numerics; using Content.Client.Humanoid; using Content.Client.Inventory; using Content.Shared.GameTicking; @@ -215,10 +216,10 @@ public sealed partial class GeneralStationRecordConsoleWindow : DefaultWindow GiveDummyJobClothes(_previewDummy, record.JobPrototype, profile); var spriteViewBox = new BoxContainer(); - var sprite = entityManager.GetComponent(_previewDummy); + // var sprite = entityManager.GetComponent(_previewDummy); - spriteViewBox.AddChild(new SpriteView() { Sprite = sprite, Scale = (5, 5)}); - spriteViewBox.AddChild(new SpriteView() { Sprite = sprite, Scale = (5, 5), OverrideDirection = Direction.East}); + spriteViewBox.AddChild(new SpriteView(_previewDummy, entityManager) { Scale = new Vector2(5, 5)}); + spriteViewBox.AddChild(new SpriteView(_previewDummy, entityManager) { Scale = new Vector2(5, 5), OverrideDirection = Direction.East}); return spriteViewBox; } diff --git a/Content.Server/Body/Systems/RespiratorSystem.cs b/Content.Server/Body/Systems/RespiratorSystem.cs index 378ce439fc..9eef980ebf 100644 --- a/Content.Server/Body/Systems/RespiratorSystem.cs +++ b/Content.Server/Body/Systems/RespiratorSystem.cs @@ -235,9 +235,10 @@ namespace Content.Server.Body.Systems // WD start private void OnHandInteract(EntityUid uid, RespiratorComponent component, InteractHandEvent args) { - if (CanCPR(uid, component, args.User)) - DoCPR(uid, component, args.User); + if (!CanCPR(uid, component, args.User)) + return; + DoCPR(uid, component, args.User); args.Handled = true; } diff --git a/Content.Server/White/AntiCringeSystem/AntiCringeComponent.cs b/Content.Server/White/AntiCringeSystem/AntiCringeComponent.cs index 1d38b84dfa..f3fa95a319 100644 --- a/Content.Server/White/AntiCringeSystem/AntiCringeComponent.cs +++ b/Content.Server/White/AntiCringeSystem/AntiCringeComponent.cs @@ -1,7 +1,7 @@ namespace Content.Server.White.AntiCringeSystem; [RegisterComponent] -public sealed class AntiCringeComponent : Component +public sealed partial class AntiCringeComponent : Component { } diff --git a/Content.Server/White/Other/OnDeath.cs b/Content.Server/White/Other/OnDeath.cs index 107a5b4da6..9420f7cfcf 100644 --- a/Content.Server/White/Other/OnDeath.cs +++ b/Content.Server/White/Other/OnDeath.cs @@ -63,7 +63,8 @@ public sealed class OnDeath : EntitySystem } var newStream = _audio.PlayEntity(HeartSounds, uid, uid, AudioParams.Default.WithLoop(true)); - _playingStreams[uid] = newStream.Value.Entity; + if (newStream != null) + _playingStreams[uid] = newStream.Value.Entity; } private void StopPlayingStream(EntityUid uid) diff --git a/Resources/Prototypes/White/Actions/emotes.yml b/Resources/Prototypes/White/Actions/emotes.yml index d924cdd4c7..ddcfb3760f 100644 --- a/Resources/Prototypes/White/Actions/emotes.yml +++ b/Resources/Prototypes/White/Actions/emotes.yml @@ -3,27 +3,36 @@ id: EmoteActionFlip name: emote-flip-action-name description: emote-flip-action-description - icon: White/Actions/EmoteFlip.png - event: !type:EmoteActionEvent - emote: EmoteFlip + nospawn: true + components: + - type: InstantAction + icon: White/Actions/EmoteFlip.png + event: !type:EmoteActionEvent + emote: EmoteFlip # jump animation - type: entity id: EmoteActionJump name: emote-jump-action-name description: emote-jump-action-description - icon: White/Actions/EmoteJump.png - event: !type:EmoteActionEvent - emote: EmoteJump + nospawn: true + components: + - type: InstantAction + icon: White/Actions/EmoteJump.png + event: !type:EmoteActionEvent + emote: EmoteJump # turn around in 4 directions animation - type: entity id: EmoteActionTurn name: emote-turn-action-name description: emote-turn-action-description - icon: White/Actions/EmoteTurn.png - event: !type:EmoteActionEvent - emote: EmoteTurn + nospawn: true + components: + - type: InstantAction + icon: White/Actions/EmoteTurn.png + event: !type:EmoteActionEvent + emote: EmoteTurn # Using EmoteAnimation from IC action chat diff --git a/Resources/Prototypes/White/Species/felinid.yml b/Resources/Prototypes/White/Species/felinid.yml index 12f8e27734..5cc33f76a3 100644 --- a/Resources/Prototypes/White/Species/felinid.yml +++ b/Resources/Prototypes/White/Species/felinid.yml @@ -3,6 +3,7 @@ name: species-name-felinid roundStart: true prototype: MobFelinid + sprites: MobHumanSprites markingLimits: MobFelinidMarkingLimits dollPrototype: MobFelinidDummy skinColoration: HumanToned