Improves powernet destruction.

While we currently do hard del datums this is a step towards a better world.
This commit is contained in:
PsiOmegaDelta
2015-09-16 08:00:22 +02:00
parent ce4de51ba3
commit f8a38ec7cf
+7 -1
View File
@@ -19,8 +19,14 @@
..()
/datum/powernet/Destroy()
for(var/obj/structure/cable/C in cables)
cables -= C
C.powernet = null
for(var/obj/machinery/power/M in nodes)
nodes -= M
M.powernet = null
powernets -= src
..()
return ..()
//Returns the amount of excess power (before refunding to SMESs) from last tick.
//This is for machines that might adjust their power consumption using this data.