mirror of
https://github.com/DeltaV-Station/Delta-v.git
synced 2026-09-29 23:57:29 +00:00
Replace some sound PlayEntity with PlayPvs (#34317)
This commit is contained in:
committed by
deltanedas
parent
e32ea1272e
commit
65458362c5
@@ -363,6 +363,11 @@ public sealed partial class ExplosionSystem : SharedExplosionSystem
|
||||
// + if the bomb is big enough, people outside of it too
|
||||
// this is capped to 30 because otherwise really huge bombs
|
||||
// will attempt to play regular audio for people who can't hear it anyway because the epicenter is so far away
|
||||
//
|
||||
// TODO EXPLOSION redo this.
|
||||
// Use the Filter.Pvs range-multiplier option instead of AddInRange.
|
||||
// Also the default PVS range is 25*2 = 50. So capping it at 30 makes no sense here.
|
||||
// So actually maybe don't use Filter.Pvs at all and only use AddInRange?
|
||||
var audioRange = Math.Min(iterationIntensity.Count * 2, MaxExplosionAudioRange);
|
||||
var filter = Filter.Pvs(pos).AddInRange(pos, audioRange);
|
||||
var sound = iterationIntensity.Count < queued.Proto.SmallSoundIterationThreshold
|
||||
|
||||
Reference in New Issue
Block a user