mirror of
https://github.com/PolarisSS13/Polaris.git
synced 2026-01-06 07:22:42 +00:00
Merge pull request #2102 from Ravensdale/master
Station-wide boom sound
This commit is contained in:
@@ -14,14 +14,20 @@ proc/explosion(turf/epicenter, devastation_range, heavy_impact_range, light_impa
|
||||
epicenter = get_turf(epicenter)
|
||||
if(!epicenter) return
|
||||
|
||||
|
||||
playsound(epicenter, 'sound/effects/explosionfar.ogg', 100, 1, round(devastation_range*2,1) )
|
||||
playsound(epicenter, "explosion", 100, 1, round(devastation_range,1) )
|
||||
|
||||
var/close = range(world.view+round(devastation_range,1), epicenter)
|
||||
// to all distanced mobs play a different sound
|
||||
for(var/mob/M in world) if(M.z == epicenter.z) if(!(M in close))
|
||||
// check if the mob can hear
|
||||
if(M.ear_deaf <= 0 || !M.ear_deaf) if(!istype(M.loc,/turf/space))
|
||||
M << 'explosionfar.ogg'
|
||||
if(adminlog)
|
||||
message_admins("Explosion with size ([devastation_range], [heavy_impact_range], [light_impact_range]) in area [epicenter.loc.name] ([epicenter.x],[epicenter.y],[epicenter.z])")
|
||||
log_game("Explosion with size ([devastation_range], [heavy_impact_range], [light_impact_range]) in area [epicenter.loc.name] ")
|
||||
|
||||
playsound(epicenter, 'sound/effects/explosionfar.ogg', 100, 1, round(devastation_range*2,1) )
|
||||
playsound(epicenter, "explosion", 100, 1, round(devastation_range,1) )
|
||||
|
||||
|
||||
var/lighting_controller_was_processing = lighting_controller.processing //Pause the lighting updates for a bit
|
||||
lighting_controller.processing = 0
|
||||
var/powernet_rebuild_was_deferred_already = defer_powernet_rebuild
|
||||
@@ -74,4 +80,4 @@ proc/explosion(turf/epicenter, devastation_range, heavy_impact_range, light_impa
|
||||
|
||||
proc/secondaryexplosion(turf/epicenter, range)
|
||||
for(var/turf/tile in range(range, epicenter))
|
||||
tile.ex_act(2)
|
||||
tile.ex_act(2)
|
||||
|
||||
Reference in New Issue
Block a user