Fixes packages AME shielding not instantly being deleted after being used, allowing multiple sections of shielding to be made from a single package.

The issue came from a sleep(10) in the New() of the shielding units, which was delaying the qdel(src) in the code that created the shielding.
This commit is contained in:
PJB3005
2015-08-16 15:58:32 +02:00
committed by Rob Nelson
parent efa499a066
commit 6fe9873ad2
2 changed files with 8 additions and 4 deletions

View File

@@ -34,8 +34,8 @@ proc/cardinalrange(var/center)
..(loc)
machines -= src
power_machines += src
sleep(10)
controllerscan()
spawn(10)
controllerscan()
/obj/machinery/am_shielding/proc/controllerscan(var/priorscan = 0)
@@ -240,7 +240,7 @@ proc/cardinalrange(var/center)
w_type = RECYK_METAL
/obj/item/device/am_shielding_container/attackby(var/obj/item/I, var/mob/user)
if(istype(I, /obj/item/device/multitool) && istype(src.loc,/turf))
if(ismultitool(I) && isturf(loc))
new/obj/machinery/am_shielding(src.loc)
qdel(src)
return

View File

@@ -0,0 +1,4 @@
author: PJB3005
delete-after: true
changes:
- bugfix: You can no longer get multiple sections of AME shielding out of 1 package of AME shielding.