Content audio (#20862)
This commit is contained in:
@@ -20,6 +20,7 @@ using Content.Shared.Throwing;
|
||||
using Robust.Server.GameStates;
|
||||
using Robust.Server.Player;
|
||||
using Robust.Shared.Audio;
|
||||
using Robust.Shared.Audio.Systems;
|
||||
using Robust.Shared.Configuration;
|
||||
using Robust.Shared.Map;
|
||||
using Robust.Shared.Physics.Components;
|
||||
@@ -48,6 +49,7 @@ public sealed partial class ExplosionSystem : EntitySystem
|
||||
[Dependency] private readonly IChatManager _chat = default!;
|
||||
[Dependency] private readonly ThrowingSystem _throwingSystem = default!;
|
||||
[Dependency] private readonly PvsOverrideSystem _pvsSys = default!;
|
||||
[Dependency] private readonly SharedAudioSystem _audio = default!;
|
||||
[Dependency] private readonly SharedTransformSystem _transformSystem = default!;
|
||||
|
||||
private EntityQuery<TransformComponent> _transformQuery;
|
||||
@@ -334,7 +336,7 @@ public sealed partial class ExplosionSystem : EntitySystem
|
||||
// play sound.
|
||||
var audioRange = iterationIntensity.Count * 5;
|
||||
var filter = Filter.Pvs(epicenter).AddInRange(epicenter, audioRange);
|
||||
SoundSystem.Play(type.Sound.GetSound(), filter, mapEntityCoords, _audioParams);
|
||||
_audio.PlayStatic(type.Sound.GetSound(), filter, mapEntityCoords, true, _audioParams);
|
||||
|
||||
return new Explosion(this,
|
||||
type,
|
||||
|
||||
Reference in New Issue
Block a user