From 3fe2776a6af9dafac9e75f3544d1e21ba2e97aaf Mon Sep 17 00:00:00 2001 From: silicons <2003111+silicons@users.noreply.github.com> Date: Wed, 13 Jan 2021 13:44:46 -0700 Subject: [PATCH] fix --- code/__DEFINES/movement.dm | 6 ++++-- code/datums/components/combat_mode.dm | 4 ++-- code/game/atoms_movable.dm | 4 ++++ code/game/sound.dm | 10 +++++++--- 4 files changed, 17 insertions(+), 7 deletions(-) diff --git a/code/__DEFINES/movement.dm b/code/__DEFINES/movement.dm index 5390077637..6a57c512c1 100644 --- a/code/__DEFINES/movement.dm +++ b/code/__DEFINES/movement.dm @@ -16,10 +16,12 @@ GLOBAL_VAR_INIT(glide_size_multiplier, 1.0) #define DELAY_TO_GLIDE_SIZE(delay) (clamp(((32 / max((delay) / world.tick_lag, 1)) * GLOB.glide_size_multiplier), MIN_GLIDE_SIZE, MAX_GLIDE_SIZE)) /// Enables smooth movement -#define SMOOTH_MOVEMENT +#ifndef SMOOTH_MOVEMENT + #define SMOOTH_MOVEMENT TRUE +#endif /// Set appearance flags in vars -#ifdef SMOOTH_MOVEMENT +#if SMOOTH_MOVEMENT #define SET_APPEARANCE_FLAGS(flags) appearance_flags = (flags | LONG_GLIDE) #else #define SET_APPEARANCE_FLAGS(flags) appearance_flags = flags diff --git a/code/datums/components/combat_mode.dm b/code/datums/components/combat_mode.dm index 0ffc32542b..b9952e9133 100644 --- a/code/datums/components/combat_mode.dm +++ b/code/datums/components/combat_mode.dm @@ -87,7 +87,7 @@ else to_chat(source, self_message) if(playsound) - source.playsound_local(source, 'sound/misc/ui_toggle.ogg', 50, FALSE, pressure_affected = FALSE, use_reverb= FALSE) //Sound from interbay! + source.playsound_local(source, 'sound/misc/ui_toggle.ogg', 50, FALSE, pressure_affected = FALSE) //Sound from interbay! RegisterSignal(source, COMSIG_MOB_CLIENT_MOUSEMOVE, .proc/onMouseMove) RegisterSignal(source, COMSIG_MOVABLE_MOVED, .proc/on_move) RegisterSignal(source, COMSIG_MOB_CLIENT_MOVE, .proc/on_client_move) @@ -114,7 +114,7 @@ else to_chat(source, self_message) if(playsound) - source.playsound_local(source, 'sound/misc/ui_toggleoff.ogg', 50, FALSE, pressure_affected = FALSE, use_reverb= FALSE) //Slightly modified version of the toggleon sound! + source.playsound_local(source, 'sound/misc/ui_toggleoff.ogg', 50, FALSE, pressure_affected = FALSE) //Slightly modified version of the toggleon sound! UnregisterSignal(source, list(COMSIG_MOB_CLIENT_MOUSEMOVE, COMSIG_MOVABLE_MOVED, COMSIG_MOB_CLIENT_MOVE)) if(hud_icon) hud_icon.combat_on = FALSE diff --git a/code/game/atoms_movable.dm b/code/game/atoms_movable.dm index 8df787aecd..128995b5bc 100644 --- a/code/game/atoms_movable.dm +++ b/code/game/atoms_movable.dm @@ -303,6 +303,7 @@ pulledby.stop_pulling() /atom/movable/proc/set_glide_size(target = 8, recursive = TRUE) +#if SMOOTH_MOVEMENT // SEND_SIGNAL(src, COMSIG_MOVABLE_UPDATE_GLIDE_SIZE, target) glide_size = target @@ -312,6 +313,9 @@ if(recursive) recursive_pulled_glidesize_update() +#else + return +#endif ///Sets the anchored var and returns if it was sucessfully changed or not. /atom/movable/proc/set_anchored(anchorvalue) diff --git a/code/game/sound.dm b/code/game/sound.dm index 0ba16c967d..5c81f77830 100644 --- a/code/game/sound.dm +++ b/code/game/sound.dm @@ -174,9 +174,13 @@ distance_multiplier - Can be used to multiply the distance at which the sound is if(A.sound_environment != SOUND_ENVIRONMENT_NONE) S.environment = A.sound_environment - if(use_reverb && S.environment != SOUND_ENVIRONMENT_NONE) //We have reverb, reset our echo setting - S.echo[3] = 0 //Room setting, 0 means normal reverb - S.echo[4] = 0 //RoomHF setting, 0 means normal reverb. + if(use_reverb) + if(S.environment == SOUND_ENVIRONMENT_NONE) //We have reverb, reset our echo setting + S.environment = SOUND_ENVIRONMENT_CONCERT_HALL + S.echo = list(0, null, -10000, null, null, null, null, null, null, null, null, null, null, 1, 1, 1, null, null) + else + S.echo[3] = 0 //Room setting, 0 means normal reverb + S.echo[4] = 0 //RoomHF setting, 0 means normal reverb. SEND_SOUND(src, S)