From 211ba8c7bdc558de5ebfd70cc77f8ea762c40184 Mon Sep 17 00:00:00 2001 From: AJCM-git <60196617+AJCM-git@users.noreply.github.com> Date: Mon, 8 May 2023 02:14:48 -0400 Subject: [PATCH] Fix buckling sounds (#16142) --- Content.Shared/Buckle/SharedBuckleSystem.Buckle.cs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Content.Shared/Buckle/SharedBuckleSystem.Buckle.cs b/Content.Shared/Buckle/SharedBuckleSystem.Buckle.cs index 8a2af7996a..405cce0ebe 100644 --- a/Content.Shared/Buckle/SharedBuckleSystem.Buckle.cs +++ b/Content.Shared/Buckle/SharedBuckleSystem.Buckle.cs @@ -354,7 +354,8 @@ public abstract partial class SharedBuckleSystem ReAttach(buckleUid, strapUid, buckleComp, strapComp); SetBuckledTo(buckleUid,strapUid, strapComp, buckleComp); - _audioSystem.PlayPredicted(strapComp.BuckleSound, strapUid, buckleUid); + // TODO user is currently set to null because if it isn't the sound fails to play in some situations, fix that + _audioSystem.PlayPredicted(strapComp.BuckleSound, strapUid, null); var ev = new BuckleChangeEvent(strapUid, buckleUid, true); RaiseLocalEvent(ev.BuckledEntity, ref ev); @@ -480,7 +481,7 @@ public abstract partial class SharedBuckleSystem } AppearanceSystem.SetData(strapUid, StrapVisuals.State, strapComp.BuckledEntities.Count != 0); - _audioSystem.PlayPredicted(strapComp.UnbuckleSound, strapUid, buckleUid); + _audioSystem.PlayPredicted(strapComp.UnbuckleSound, strapUid, null); var ev = new BuckleChangeEvent(strapUid, buckleUid, false); RaiseLocalEvent(buckleUid, ref ev); -- 2.51.2