mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-29 16:18:01 +01:00
[NO GBP] Fixes catwalks over open space not making a sound when walked over. (#79738)
## About The Pull Request See the title. ## Why It's Good For The Game Actually fixing #78646. ## Changelog 🆑 fix: Fixed catwalks over open space not making a sound when walked over. /🆑
This commit is contained in:
@@ -31,5 +31,7 @@
|
||||
|
||||
///from /datum/element/footstep/prepare_step(): (list/steps)
|
||||
#define COMSIG_TURF_PREPARE_STEP_SOUND "turf_prepare_step_sound"
|
||||
//stops element/footstep/proc/prepare_step() from returning null if the turf itself has no sound
|
||||
#define FOOTSTEP_OVERRIDEN (1<<0)
|
||||
///from base of datum/thrownthing/finalize(): (turf/turf, atom/movable/thrownthing) when something is thrown and lands on us
|
||||
#define COMSIG_TURF_MOVABLE_THROW_LANDED "turf_movable_throw_landed"
|
||||
|
||||
@@ -94,9 +94,9 @@
|
||||
return
|
||||
|
||||
. = list(FOOTSTEP_MOB_SHOE = turf.footstep, FOOTSTEP_MOB_BAREFOOT = turf.barefootstep, FOOTSTEP_MOB_HEAVY = turf.heavyfootstep, FOOTSTEP_MOB_CLAW = turf.clawfootstep, STEP_SOUND_PRIORITY = STEP_SOUND_NO_PRIORITY)
|
||||
SEND_SIGNAL(turf, COMSIG_TURF_PREPARE_STEP_SOUND, .)
|
||||
var/overriden = SEND_SIGNAL(turf, COMSIG_TURF_PREPARE_STEP_SOUND, .) & FOOTSTEP_OVERRIDEN
|
||||
//The turf has no footstep sound (e.g. open space) and none of the objects on that turf (e.g. catwalks) overrides it
|
||||
if(isnull(turf.footstep))
|
||||
if(!overriden && isnull(turf.footstep))
|
||||
return null
|
||||
return .
|
||||
|
||||
|
||||
@@ -78,3 +78,4 @@
|
||||
steps[FOOTSTEP_MOB_HEAVY] = heavyfootstep
|
||||
steps[FOOTSTEP_MOB_CLAW] = clawfootstep
|
||||
steps[STEP_SOUND_PRIORITY] = priority
|
||||
return FOOTSTEP_OVERRIDEN
|
||||
|
||||
Reference in New Issue
Block a user