From a3c19ad4392d6dfd2a3167097e21cde39d07ede3 Mon Sep 17 00:00:00 2001 From: Swept Date: Fri, 27 Aug 2021 15:36:30 -0700 Subject: [PATCH] Replaces outdated code in GravitySystem.cs (#4505) --- Content.Server/Gravity/EntitySystems/GravitySystem.cs | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/Content.Server/Gravity/EntitySystems/GravitySystem.cs b/Content.Server/Gravity/EntitySystems/GravitySystem.cs index 3778b8a3c5..630719710f 100644 --- a/Content.Server/Gravity/EntitySystems/GravitySystem.cs +++ b/Content.Server/Gravity/EntitySystems/GravitySystem.cs @@ -137,15 +137,8 @@ namespace Content.Server.Gravity.EntitySystems { _gridsToShake[gridId] = shakeTimes; } - // Play the gravity sound - foreach (var player in _playerManager.GetAllPlayers()) - { - if (player.AttachedEntity == null - || player.AttachedEntity.Transform.GridID != gridId) - continue; - SoundSystem.Play(Filter.Pvs(player.AttachedEntity), comp.GravityShakeSound.GetSound(), player.AttachedEntity); - } + SoundSystem.Play(Filter.BroadcastGrid(gridId), comp.GravityShakeSound.GetSound(), AudioParams.Default.WithVolume(-2f)); } private void ShakeGrids()