mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-30 00:29:02 +01:00
Mass-replacement of stat to machine_stat (#48758)
Living and machine stat vars are pretty different, one uses flags and other number-defines. This should make some other mass-replacements and searches a bit easier.
This commit is contained in:
@@ -64,7 +64,7 @@
|
||||
to_chat(user, "<span class='warning'>Access denied.</span>")
|
||||
return
|
||||
if(controller && !controller.busy && door)
|
||||
if(controller.stat & NOPOWER)
|
||||
if(controller.machine_stat & NOPOWER)
|
||||
return
|
||||
busy = TRUE
|
||||
update_icon()
|
||||
@@ -83,7 +83,7 @@
|
||||
update_icon()
|
||||
|
||||
/obj/machinery/doorButtons/access_button/update_icon_state()
|
||||
if(stat & NOPOWER)
|
||||
if(machine_stat & NOPOWER)
|
||||
icon_state = "access_button_off"
|
||||
else
|
||||
if(busy)
|
||||
@@ -162,7 +162,7 @@
|
||||
A.safe = FALSE //Door crushies, manual door after all. Set every time in case someone changed it, safe doors can end up waiting forever.
|
||||
A.unbolt()
|
||||
if(A.close())
|
||||
if(stat & NOPOWER || lostPower || !A || QDELETED(A))
|
||||
if(machine_stat & NOPOWER || lostPower || !A || QDELETED(A))
|
||||
goIdle(TRUE)
|
||||
return FALSE
|
||||
A.bolt()
|
||||
@@ -209,7 +209,7 @@
|
||||
|
||||
/obj/machinery/doorButtons/airlock_controller/proc/do_openDoor(obj/machinery/door/airlock/A)
|
||||
if(A && A.open())
|
||||
if(stat | (NOPOWER) && !lostPower && A && !QDELETED(A))
|
||||
if(machine_stat | (NOPOWER) && !lostPower && A && !QDELETED(A))
|
||||
A.bolt()
|
||||
goIdle(TRUE)
|
||||
|
||||
@@ -221,7 +221,7 @@
|
||||
updateUsrDialog()
|
||||
|
||||
/obj/machinery/doorButtons/airlock_controller/process()
|
||||
if(stat & NOPOWER)
|
||||
if(machine_stat & NOPOWER)
|
||||
return
|
||||
if(busy == CYCLE_EXTERIOR)
|
||||
cycleOpen(exteriorAirlock)
|
||||
@@ -230,7 +230,7 @@
|
||||
|
||||
/obj/machinery/doorButtons/airlock_controller/power_change()
|
||||
. = ..()
|
||||
if(stat & NOPOWER)
|
||||
if(machine_stat & NOPOWER)
|
||||
lostPower = TRUE
|
||||
else
|
||||
if(!busy)
|
||||
@@ -244,7 +244,7 @@
|
||||
exteriorAirlock = A
|
||||
|
||||
/obj/machinery/doorButtons/airlock_controller/update_icon_state()
|
||||
if(stat & NOPOWER)
|
||||
if(machine_stat & NOPOWER)
|
||||
icon_state = "access_control_off"
|
||||
return
|
||||
if(busy || lostPower)
|
||||
|
||||
Reference in New Issue
Block a user