mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-07-18 18:46:24 +01:00
Merge pull request #13616 from Heroman3003/soundchange
Makes ignore_walls ignore only walls and not other things
This commit is contained in:
+4
-2
@@ -13,9 +13,11 @@
|
||||
// Looping through the player list has the added bonus of working for mobs inside containers
|
||||
var/sound/S = sound(get_sfx(soundin))
|
||||
var/maxdistance = (world.view + extrarange) * 2 //VOREStation Edit - 3 to 2
|
||||
var/list/listeners = player_list
|
||||
var/list/listeners = player_list.Copy()
|
||||
if(!ignore_walls) //these sounds don't carry through walls
|
||||
listeners = listeners & hearers(maxdistance,turf_source)
|
||||
for(var/mob/listen in listeners)
|
||||
if(!(get_turf(listen) in hear(maxdistance,source)))
|
||||
listeners -= listen
|
||||
for(var/mob/M as anything in listeners)
|
||||
if(!M || !M.client)
|
||||
continue
|
||||
|
||||
Reference in New Issue
Block a user