From 0bc40f478e3e2e971f722de54dacdfcf59b2b9c3 Mon Sep 17 00:00:00 2001 From: FreeStylaLT Date: Fri, 2 Aug 2019 16:04:31 +0300 Subject: [PATCH] and fixes cancel not working --- code/game/objects/items/devices/enginepicker.dm | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/code/game/objects/items/devices/enginepicker.dm b/code/game/objects/items/devices/enginepicker.dm index 6092b525611..c2688bd8347 100644 --- a/code/game/objects/items/devices/enginepicker.dm +++ b/code/game/objects/items/devices/enginepicker.dm @@ -41,6 +41,8 @@ if(E) engname = E issuccessful = TRUE + else + return if(!engname) engname = DEFAULTPICK(choice.enginetype, null) //This should(?) account for a possibly scrambled list with a single entry switch(engname) @@ -52,8 +54,8 @@ issuccessful = TRUE if(issuccessful) - clearturf(T) //qdels all items / gibs all mobs on the turf. Let's not have an SM shard spawn on top of a poor sod. - new G(T) //Spawns the switch-selected engine on the chosen beacon's turf + clearturf(T) //qdels all items / gibs all mobs on the turf. Let's not have an SM shard spawn on top of a poor sod. + new G(T) //Spawns the switch-selected engine on the chosen beacon's turf var/ailist[] = list() for(var/mob/living/silicon/ai/A in GLOB.living_mob_list)