Revert "Steppy"

This reverts commit fab0590fb7.
This commit is contained in:
Guti
2025-02-06 22:43:57 +01:00
parent fab0590fb7
commit 1f7ad8f8f7
11 changed files with 30 additions and 58 deletions
-1
View File
@@ -28,7 +28,6 @@
#define FOOTSTEP_MOB_SHOE "footstep_shoe"
#define FOOTSTEP_MOB_HUMAN "footstep_human" //Warning: Only works on /mob/living/carbon/human
#define FOOTSTEP_MOB_SLIME "footstep_slime"
#define FOOTSTEP_MOB_SLITHER "foostep_slither"
#define FOOTSTEP_OBJ_MACHINE "footstep_machine"
#define FOOTSTEP_OBJ_ROBOT "footstep_robot"
-7
View File
@@ -358,10 +358,3 @@ GLOBAL_LIST_EMPTY(legacy_globals)
GLOB.legacy_globals["cameranet"] = cameranet
GLOB.legacy_globals["cultnet"] = cultnet
GLOB.legacy_globals["existing_solargrubs"] = existing_solargrubs
var/global/list/selectable_footstep = list(
"Default" = FOOTSTEP_MOB_HUMAN,
"Claw" = FOOTSTEP_MOB_CLAW,
"Light Claw" = FOOTSTEP_MOB_TESHARI,
"Slither" = FOOTSTEP_MOB_SLITHER,
)
+11 -27
View File
@@ -17,7 +17,7 @@
///Whether or not to add variation to the sounds played
var/sound_vary = FALSE
/datum/element/footstep/Attach(datum/target, footstep_type = FOOTSTEP_MOB_BAREFOOT, volume = 0.1, e_range = -8, sound_vary = FALSE)
/datum/element/footstep/Attach(datum/target, footstep_type = FOOTSTEP_MOB_BAREFOOT, volume = 0.5, e_range = -8, sound_vary = FALSE)
. = ..()
if(!ismovable(target))
return ELEMENT_INCOMPATIBLE
@@ -43,16 +43,14 @@
footstep_ret = GLOB.lightclawfootstep
if(FOOTSTEP_MOB_CLAW)
footstep_ret = GLOB.clawfootstep
if(FOOTSTEP_MOB_BAREFOOT)
footstep_ret = GLOB.barefootstep
if(FOOTSTEP_MOB_HEAVY)
footstep_ret = GLOB.heavyfootstep
if(FOOTSTEP_MOB_SHOE)
footstep_ret = GLOB.footstep
if(FOOTSTEP_MOB_SLIME)
footstep_ret = 'sound/effects/footstep/slime1.ogg'
if(FOOTSTEP_MOB_SLITHER)
footstep_ret = 'sound/effects/footstep/crawl1.ogg'
else
footstep_ret = GLOB.barefootstep
return footstep_ret
/datum/element/footstep/Detach(atom/movable/source)
@@ -81,7 +79,7 @@
var/mob/living/carbon/carbon_source = source
if(!carbon_source.get_organ(BP_L_LEG) && !carbon_source.get_organ(BP_R_LEG))
return
if(carbon_source.m_intent == I_WALK)
if(carbon_source.m_intent == "walk")
return// stealth
steps_for_living[source] += 1
var/steps = steps_for_living[source]
@@ -96,14 +94,7 @@
if(steps != 0 && !get_gravity(source)) // don't need to step as often when you hop around
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
)
. = 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)
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(!overriden && isnull(turf.footstep))
@@ -113,17 +104,12 @@
/datum/element/footstep/proc/play_simplestep(mob/living/source, atom/oldloc, direction, forced, list/old_locs, momentum_change)
SIGNAL_HANDLER
var/volume_multiplier = 0.3
if(!isturf(source.loc))
return
var/list/prepared_steps = prepare_step(source)
if(isnull(prepared_steps))
return
if(isfile(footstep_sounds) || istext(footstep_sounds))
playsound(source.loc, footstep_sounds, volume * volume_multiplier, falloff = 1, vary = sound_vary)
playsound(source.loc, footstep_sounds, volume, falloff = 1, vary = sound_vary)
return
var/turf_footstep = prepared_steps[footstep_type]
@@ -134,7 +120,7 @@
/datum/element/footstep/proc/play_humanstep(mob/living/carbon/human/source, atom/oldloc, direction, forced, list/old_locs, momentum_change)
SIGNAL_HANDLER
var/volume_multiplier = 0.3
var/volume_multiplier = 1
var/range_adjustment = 0
var/list/prepared_steps = prepare_step(source)
@@ -157,16 +143,14 @@
// we are barefoot
if(source.species.special_step_sounds)
playsound(source.loc, pick(source.species.special_step_sounds), volume, TRUE, falloff = 1, vary = sound_vary)
playsound(source.loc, pick(source.species.special_step_sounds), 50, TRUE, falloff = 1, vary = sound_vary)
else if (istype(source.species, /datum/species/shapeshifter/promethean))
playsound(source.loc, 'sound/effects/footstep/slime1.ogg', volume, TRUE, falloff = 1)
else if (source.custom_footstep == FOOTSTEP_MOB_SLITHER)
playsound(source.loc, 'sound/effects/footstep/crawl1.ogg', 15 * volume, falloff = 1, vary = sound_vary)
playsound(source.loc, 'sound/effects/footstep/slime1.ogg', 25, TRUE, falloff = 1)
else
var/barefoot_type = prepared_steps[FOOTSTEP_MOB_BAREFOOT]
var/bare_footstep_sounds
if(source.custom_footstep != FOOTSTEP_MOB_HUMAN)
bare_footstep_sounds = check_footstep_type(source.custom_footstep)
if(source.species.footstep != FOOTSTEP_MOB_HUMAN)
bare_footstep_sounds = check_footstep_type(source.species.footstep)
else
bare_footstep_sounds = GLOB.barefootstep
if(!isnull(barefoot_type) && bare_footstep_sounds[barefoot_type]) // barefoot_type can be null
+2 -2
View File
@@ -10,7 +10,7 @@
if(!isliving(target))
return ELEMENT_INCOMPATIBLE
RegisterSignal(target, COMSIG_MOVABLE_MOVED, PROC_REF(handle_sloshstep), override = TRUE)
RegisterSignal(target, COMSIG_MOVABLE_MOVED, PROC_REF(handle_footstep))
step_count = 0
vore_organs_reagents = list()
vore_footstep_volume = 0
@@ -22,7 +22,7 @@
step_count -= source
return ..()
/datum/element/slosh/proc/handle_sloshstep(mob/living/source)
/datum/element/slosh/proc/handle_footstep(mob/living/source)
SIGNAL_HANDLER
if(ishuman(source))
@@ -16,7 +16,6 @@
var/voice_freq = 0
var/voice_sound = "beep-boop"
var/custom_speech_bubble = "default"
var/custom_footstep = FOOTSTEP_MOB_HUMAN
// Definition of the stuff for Sizing
/datum/category_item/player_setup_item/vore/size
@@ -33,7 +32,6 @@
pref.voice_freq = save_data["voice_freq"]
pref.voice_sound = save_data["voice_sound"]
pref.custom_speech_bubble = save_data["custom_speech_bubble"]
pref.custom_footstep = save_data["custom_footstep"]
/datum/category_item/player_setup_item/vore/size/save_character(list/save_data)
save_data["size_multiplier"] = pref.size_multiplier
@@ -45,7 +43,6 @@
save_data["voice_freq"] = pref.voice_freq
save_data["voice_sound"] = pref.voice_sound
save_data["custom_speech_bubble"] = pref.custom_speech_bubble
save_data["custom_footstep"] = pref.custom_footstep
/datum/category_item/player_setup_item/vore/size/sanitize_character()
pref.weight_vr = sanitize_integer(pref.weight_vr, WEIGHT_MIN, WEIGHT_MAX, initial(pref.weight_vr))
@@ -59,8 +56,6 @@
pref.size_multiplier = initial(pref.size_multiplier)
if(!(pref.custom_speech_bubble in selectable_speech_bubbles))
pref.custom_speech_bubble = "default"
if(!(pref.custom_footstep))
pref.custom_footstep = "Default"
/datum/category_item/player_setup_item/vore/size/copy_to_mob(var/mob/living/carbon/human/character)
character.weight = pref.weight_vr
@@ -75,7 +70,6 @@
else
character.voice_sounds_list = get_talk_sound(pref.voice_sound)
character.custom_speech_bubble = pref.custom_speech_bubble
character.custom_footstep = pref.custom_footstep
/datum/category_item/player_setup_item/vore/size/content(var/mob/user)
. += "<br>"
@@ -86,7 +80,6 @@
. += span_bold("Voice Sounds:") + " <a href='byond://?src=\ref[src];voice_sounds_list=1'>[pref.voice_sound]</a><br>"
. += "<a href='byond://?src=\ref[src];voice_test=1'><b>Test Selected Voice</b></a><br>"
. += span_bold("Custom Speech Bubble:") + " <a href='byond://?src=\ref[src];customize_speech_bubble=1'>[pref.custom_speech_bubble]</a><br>"
. += "<b>Custom Footstep Sounds:</b><a href='?src=\ref[src];customize_footsteps=1'>[pref.custom_footstep]</a><br>"
. += "<br>"
. += span_bold("Relative Weight:") + " <a href='byond://?src=\ref[src];weight=1'>[pref.weight_vr]</a><br>"
. += span_bold("Weight Gain Rate:") + " <a href='byond://?src=\ref[src];weight_gain=1'>[pref.weight_gain]</a><br>"
@@ -194,13 +187,6 @@
pref.custom_speech_bubble = choice
return TOPIC_REFRESH
else if(href_list["customize_footsteps"])
var/list/footstep_choice = selectable_footstep
var/choice = tgui_input_list(user, "What footstep sounds would your character make?", "Custom Foostep Sounds", footstep_choice)
if(choice)
pref.custom_footstep = footstep_choice[choice]
return TOPIC_REFRESH
else if(href_list["voice_test"])
var/sound/S
switch(pref.voice_sound)
-2
View File
@@ -8,8 +8,6 @@
if (!default_language && species_language)
default_language = GLOB.all_languages[species_language]
AddElement(/datum/element/footstep, custom_footstep, -1, -6)
/mob/living/carbon/Life()
..()
+14
View File
@@ -710,6 +710,12 @@
failed_last_breath = 0 //So mobs that died of oxyloss don't revive and have perpetual out of breath.
reload_fullscreen()
RemoveElement(/datum/element/footstep)
if(ishuman(src))
var/mob/living/carbon/human/H = src
H.set_footsteps(H.species.footstep)
return
/mob/living/proc/UpdateDamageIcon()
@@ -1352,3 +1358,11 @@
to_chat(src, span_notice("You are [toggled_sleeping ? "now sleeping. Use the Sleep verb again to wake up" : "no longer sleeping"]."))
if(toggled_sleeping)
Sleeping(1)
/mob/living/proc/set_footsteps(footstep_sounds = FOOTSTEP_MOB_HUMAN)
AddElement(/datum/element/footstep, footstep_sounds, 1, -6)
/*
/mob/living/proc/set_slosh()
AddElement(/datum/element/slosh)
*/
@@ -37,8 +37,6 @@
init_id()
init_subsystems()
AddElement(/datum/element/footstep, FOOTSTEP_MOB_SHOE, 0.75, -6)
/mob/living/silicon/Destroy()
silicon_mob_list -= src
for(var/datum/alarm_handler/AH in SSalarm.all_handlers)
@@ -205,7 +205,6 @@
if(CONFIG_GET(flag/allow_simple_mob_recolor))
add_verb(src, /mob/living/simple_mob/proc/ColorMate)
AddElement(/datum/element/footstep, FOOTSTEP_MOB_SHOE, 0.5, -6) // Need to go through all of the mobs to give them proper footsteps...
return ..()
-2
View File
@@ -241,5 +241,3 @@
var/list/viruses
var/list/resistances
var/custom_footstep = FOOTSTEP_MOB_SHOE
@@ -593,6 +593,9 @@
new_character.update_icons_body()
new_character.update_transform() //VOREStation Edit
new_character.set_footsteps(chosen_species.footstep)
// new_character.set_slosh()
new_character.key = key //Manually transfer the key to log them in
return new_character