Immursive Audio 2

This commit is contained in:
Letter N
2020-12-24 11:06:49 +08:00
parent 35edf3589b
commit 56fb81d02c
29 changed files with 388 additions and 210 deletions
+8 -8
View File
@@ -46,7 +46,7 @@
var/mob/living/LM = parent
if(!T.footstep || LM.buckled || !CHECK_MOBILITY(LM, MOBILITY_STAND) || LM.buckled || LM.throwing || (LM.movement_type & (VENTCRAWLING | FLYING)))
if (LM.lying && !LM.buckled && !(!T.footstep || LM.movement_type & (VENTCRAWLING | FLYING))) //play crawling sound if we're lying
playsound(T, 'sound/effects/footstep/crawl1.ogg', 15 * volume)
playsound(T, 'sound/effects/footstep/crawl1.ogg', 15 * volume, falloff_distance = 1)
return
if(HAS_TRAIT(LM, TRAIT_SILENT_STEP))
@@ -75,7 +75,7 @@
if(!T)
return
if(isfile(footstep_sounds) || istext(footstep_sounds))
playsound(T, footstep_sounds, volume)
playsound(T, footstep_sounds, volume, falloff_distance = 1)
return
var/turf_footstep
switch(footstep_type)
@@ -89,7 +89,7 @@
turf_footstep = T.footstep
if(!turf_footstep)
return
playsound(T, pick(footstep_sounds[turf_footstep][1]), footstep_sounds[turf_footstep][2] * volume, TRUE, footstep_sounds[turf_footstep][3] + e_range)
playsound(T, pick(footstep_sounds[turf_footstep][1]), footstep_sounds[turf_footstep][2] * volume, TRUE, footstep_sounds[turf_footstep][3] + e_range, falloff_distance = 1)
/datum/component/footstep/proc/play_humanstep()
var/turf/open/T = prepare_step()
@@ -114,10 +114,10 @@
turf_footstep = T.footstep
L = GLOB.footstep
if(FOOTSTEP_MOB_SLIME)
playsound(T, 'sound/effects/footstep/slime1.ogg', 50 * volume)
playsound(T, 'sound/effects/footstep/slime1.ogg', 50 * volume, falloff_distance = 1)
return
if(FOOTSTEP_MOB_CRAWL)
playsound(T, 'sound/effects/footstep/crawl1.ogg', 50 * volume)
playsound(T, 'sound/effects/footstep/crawl1.ogg', 50 * volume, falloff_distance = 1)
return
special = TRUE
else
@@ -126,13 +126,13 @@
playsound(T, pick(GLOB.footstep[T.footstep][1]),
GLOB.footstep[T.footstep][2] * volume,
TRUE,
GLOB.footstep[T.footstep][3] + e_range)
GLOB.footstep[T.footstep][3] + e_range, falloff_distance = 1)
return
if(!special && H.dna.species.special_step_sounds)
playsound(T, pick(H.dna.species.special_step_sounds), 50, TRUE)
playsound(T, pick(H.dna.species.special_step_sounds), 50, TRUE, falloff_distance = 1)
else
playsound(T, pick(L[turf_footstep][1]),
L[turf_footstep][2] * volume,
TRUE,
L[turf_footstep][3] + e_range)
L[turf_footstep][3] + e_range, falloff_distance = 1)