Add local APC cache to /area (#61655)

About The Pull Request

for(var/obj/machinery/power/apc/APC in GLOB.apcs_list) in get_apc makes chuck norris shed a tear
Why It's Good For The Game

tears are bad
Changelog

cl
code: /area now retains a local reference to the APC in the area, if any
/cl
This commit is contained in:
esainane
2021-10-02 14:31:09 +13:00
committed by GitHub
parent c7b9ff520f
commit 30da0af679
8 changed files with 50 additions and 51 deletions
+1 -1
View File
@@ -93,7 +93,7 @@
return
var/turf/T = get_turf(on_wall) //the user is not where it needs to be.
var/area/A = get_area(user)
if(A.get_apc())
if(A.apc)
to_chat(user, span_warning("This area already has an APC!"))
return //only one APC per area
if(!A.requires_power)