diff --git a/code/game/gamemodes/events/power_failure.dm b/code/game/gamemodes/events/power_failure.dm index 19c009356b7..c8848cd3ee8 100644 --- a/code/game/gamemodes/events/power_failure.dm +++ b/code/game/gamemodes/events/power_failure.dm @@ -7,6 +7,9 @@ for(var/obj/machinery/power/smes/S in world) if(istype(get_area(S), /area/turret_protected) || S.z != 1) continue + S.last_charge = S.charge + S.last_output = S.output + S.last_online = S.online S.charge = 0 S.output = 0 S.online = 0 @@ -60,9 +63,9 @@ for(var/obj/machinery/power/smes/S in world) if(S.z != 1) continue - S.charge = S.capacity - S.output = 200000 - S.online = 1 + S.charge = S.last_charge + S.output = S.last_output + S.online = S.last_online S.updateicon() S.power_change() for(var/area/A in world) diff --git a/code/modules/power/smes.dm b/code/modules/power/smes.dm index ecc7acb8173..a5e0f52d726 100644 --- a/code/modules/power/smes.dm +++ b/code/modules/power/smes.dm @@ -23,7 +23,10 @@ var/online = 1 var/n_tag = null var/obj/machinery/power/terminal/terminal = null - + //Holders for powerout event. + var/last_output = 0 + var/last_charge = 0 + var/last_online = 0 /obj/machinery/power/smes/New() ..()