mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-22 11:37:40 +01:00
Clearer defines
This commit is contained in:
@@ -128,6 +128,6 @@
|
||||
#define AI_DISPLAY_MODE_BSOD 2
|
||||
|
||||
// Door operations
|
||||
#define OPENING 1
|
||||
#define CLOSING 2
|
||||
#define MALF 3
|
||||
#define DOOR_OPENING 1
|
||||
#define DOOR_CLOSING 2
|
||||
#define DOOR_MALF 3
|
||||
|
||||
@@ -155,7 +155,7 @@
|
||||
D.activate_alarm()
|
||||
if(D.welded)
|
||||
continue
|
||||
if(D.operating && D.operating != CLOSING)
|
||||
if(D.operating && D.operating != DOOR_CLOSING)
|
||||
D.nextstate = FD_CLOSED
|
||||
else if(!D.density)
|
||||
INVOKE_ASYNC(D, /obj/machinery/door/firedoor.proc/close)
|
||||
@@ -170,7 +170,7 @@
|
||||
D.deactivate_alarm()
|
||||
if(D.welded)
|
||||
continue
|
||||
if(D.operating && D.operating != OPENING)
|
||||
if(D.operating && D.operating != DOOR_OPENING)
|
||||
D.nextstate = FD_OPEN
|
||||
else if(D.density)
|
||||
INVOKE_ASYNC(D, /obj/machinery/door/firedoor.proc/open)
|
||||
@@ -256,7 +256,7 @@
|
||||
if(D.welded)
|
||||
continue // Alarm is toggled, but door stuck
|
||||
if(D.operating)
|
||||
if((D.operating == OPENING && opening) || (D.operating == CLOSING && !opening))
|
||||
if((D.operating == DOOR_OPENING && opening) || (D.operating == DOOR_CLOSING && !opening))
|
||||
continue
|
||||
else
|
||||
D.nextstate = opening ? FD_OPEN : FD_CLOSED
|
||||
|
||||
@@ -1233,7 +1233,7 @@ GLOBAL_LIST_EMPTY(airlock_emissive_underlays)
|
||||
if(!density)
|
||||
return TRUE
|
||||
SEND_SIGNAL(src, COMSIG_AIRLOCK_OPEN)
|
||||
operating = OPENING
|
||||
operating = DOOR_OPENING
|
||||
update_icon(AIRLOCK_OPENING, 1)
|
||||
sleep(1)
|
||||
set_opacity(0)
|
||||
@@ -1274,7 +1274,7 @@ GLOBAL_LIST_EMPTY(airlock_emissive_underlays)
|
||||
killthis.ex_act(EXPLODE_HEAVY)//Smashin windows
|
||||
|
||||
SEND_SIGNAL(src, COMSIG_AIRLOCK_CLOSE)
|
||||
operating = CLOSING
|
||||
operating = DOOR_CLOSING
|
||||
update_icon(AIRLOCK_CLOSING, 1)
|
||||
layer = CLOSED_DOOR_LAYER
|
||||
if(!override)
|
||||
@@ -1326,7 +1326,7 @@ GLOBAL_LIST_EMPTY(airlock_emissive_underlays)
|
||||
|
||||
/obj/machinery/door/airlock/emag_act(mob/user)
|
||||
if(!operating && density && arePowerSystemsOn() && !emagged)
|
||||
operating = MALF
|
||||
operating = DOOR_MALF
|
||||
update_icon(AIRLOCK_EMAG, 1)
|
||||
sleep(6)
|
||||
if(QDELETED(src))
|
||||
@@ -1341,7 +1341,7 @@ GLOBAL_LIST_EMPTY(airlock_emissive_underlays)
|
||||
/obj/machinery/door/airlock/cmag_act(mob/user)
|
||||
if(operating || HAS_TRAIT(src, TRAIT_CMAGGED) || !density || !arePowerSystemsOn())
|
||||
return
|
||||
operating = MALF
|
||||
operating = DOOR_MALF
|
||||
update_icon(AIRLOCK_EMAG, 1)
|
||||
sleep(6)
|
||||
if(QDELETED(src))
|
||||
|
||||
@@ -383,7 +383,7 @@
|
||||
if(operating)
|
||||
return
|
||||
SEND_SIGNAL(src, COMSIG_DOOR_OPEN)
|
||||
operating = OPENING
|
||||
operating = DOOR_OPENING
|
||||
do_animate("opening")
|
||||
set_opacity(0)
|
||||
sleep(5)
|
||||
@@ -413,7 +413,7 @@
|
||||
return
|
||||
|
||||
SEND_SIGNAL(src, COMSIG_DOOR_CLOSE)
|
||||
operating = CLOSING
|
||||
operating = DOOR_CLOSING
|
||||
|
||||
do_animate("closing")
|
||||
layer = closingLayer
|
||||
|
||||
@@ -169,7 +169,7 @@
|
||||
if(emagged)
|
||||
return 0
|
||||
if(!operating) //in case of emag
|
||||
operating = OPENING
|
||||
operating = DOOR_OPENING
|
||||
do_animate("opening")
|
||||
set_opacity(FALSE)
|
||||
playsound(loc, 'sound/machines/windowdoor.ogg', 100, 1)
|
||||
@@ -194,7 +194,7 @@
|
||||
if(forced < 2)
|
||||
if(emagged)
|
||||
return 0
|
||||
operating = CLOSING
|
||||
operating = DOOR_CLOSING
|
||||
do_animate("closing")
|
||||
playsound(loc, 'sound/machines/windowdoor.ogg', 100, 1)
|
||||
icon_state = base_state
|
||||
@@ -252,7 +252,7 @@
|
||||
/obj/machinery/door/window/emag_act(mob/user, obj/weapon)
|
||||
if(!operating && density && !emagged)
|
||||
emagged = TRUE
|
||||
operating = MALF
|
||||
operating = DOOR_MALF
|
||||
electronics = new /obj/item/airlock_electronics/destroyed()
|
||||
flick("[base_state]spark", src)
|
||||
playsound(src, "sparks", 75, TRUE, SHORT_RANGE_SOUND_EXTRARANGE)
|
||||
@@ -265,7 +265,7 @@
|
||||
if(operating || !density || HAS_TRAIT(src, TRAIT_CMAGGED))
|
||||
return
|
||||
ADD_TRAIT(src, TRAIT_CMAGGED, "clown_emag")
|
||||
operating = MALF
|
||||
operating = DOOR_MALF
|
||||
flick("[base_state]spark", src)
|
||||
playsound(src, "sparks", 75, TRUE, SHORT_RANGE_SOUND_EXTRARANGE)
|
||||
sleep(6)
|
||||
|
||||
Reference in New Issue
Block a user