From 2f1202d5e063fc44ed3cb9fe3ab90626de4b2b83 Mon Sep 17 00:00:00 2001 From: PsiOmega Date: Fri, 29 May 2015 09:27:03 +0200 Subject: [PATCH] Airlock fixes. Changes door closing to use the same sound playing setup as door opening. Fixes #9559. --- code/game/machinery/doors/airlock.dm | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/code/game/machinery/doors/airlock.dm b/code/game/machinery/doors/airlock.dm index 58830cf9fa8..5a681e3cbc0 100644 --- a/code/game/machinery/doors/airlock.dm +++ b/code/game/machinery/doors/airlock.dm @@ -30,7 +30,7 @@ var/hasShocked = 0 //Prevents multiple shocks from happening var/secured_wires = 0 var/datum/wires/airlock/wires = null - + var/open_sound_powered = 'sound/machines/airlock.ogg' var/open_sound_unpowered = 'sound/machines/airlock_creaking.ogg' @@ -800,9 +800,9 @@ About the new airlock wires panel: qdel(src) return else if(arePowerSystemsOn()) - user << "\blue The airlock's motors resist your efforts to force it." + user << "The airlock's motors resist your efforts to force it." else if(locked) - user << "\blue The airlock's bolts prevent it from being forced." + user << "The airlock's bolts prevent it from being forced." else if(density) spawn(0) open(1) @@ -811,20 +811,20 @@ About the new airlock wires panel: else if(istype(C, /obj/item/weapon/material/twohanded/fireaxe) && !arePowerSystemsOn()) if(locked) - user << "\blue The airlock's bolts prevent it from being forced." + user << "The airlock's bolts prevent it from being forced." else if( !welded && !operating ) if(density) var/obj/item/weapon/material/twohanded/fireaxe/F = C if(F.wielded) spawn(0) open(1) else - user << "\red You need to be wielding \the [C] to do that." + user << "You need to be wielding \the [C] to do that." else var/obj/item/weapon/material/twohanded/fireaxe/F = C if(F.wielded) spawn(0) close(1) else - user << "\red You need to be wielding \the [C] to do that." + user << "You need to be wielding \the [C] to do that." else ..() @@ -855,13 +855,13 @@ About the new airlock wires panel: if(!can_open(forced)) return 0 use_power(360) //360 W seems much more appropriate for an actuator moving an industrial door capable of crushing people - + //if the door is unpowered then it doesn't make sense to hear the woosh of a pneumatic actuator if(arePowerSystemsOn()) playsound(src.loc, open_sound_powered, 100, 1) else playsound(src.loc, open_sound_unpowered, 100, 1) - + if(src.closeOther != null && istype(src.closeOther, /obj/machinery/door/airlock/) && !src.closeOther.density) src.closeOther.close() return ..() @@ -950,10 +950,10 @@ About the new airlock wires panel: take_damage(DOOR_CRUSH_DAMAGE) use_power(360) //360 W seems much more appropriate for an actuator moving an industrial door capable of crushing people - if(istype(src, /obj/machinery/door/airlock/glass)) - playsound(src.loc, 'sound/machines/windowdoor.ogg', 30, 1) + if(arePowerSystemsOn()) + playsound(src.loc, open_sound_powered, 100, 1) else - playsound(src.loc, 'sound/machines/airlock.ogg', 30, 1) + playsound(src.loc, open_sound_unpowered, 100, 1) for(var/turf/turf in locs) var/obj/structure/window/killthis = (locate(/obj/structure/window) in turf) if(killthis)