[s] Fixes hiding the nuke disk on the arrivals shuttle

This commit is contained in:
CitadelStationBot
2017-05-25 09:43:34 -05:00
parent 8316ad7f50
commit 2bfcc9bf1e

View File

@@ -99,7 +99,7 @@
SendToStation()
return
var/found_awake = PersonCheck()
var/found_awake = PersonCheck() || NukeDiskCheck()
if(mode == SHUTTLE_CALL)
if(found_awake)
SendToStation()
@@ -128,6 +128,12 @@
return TRUE
return FALSE
/obj/docking_port/mobile/arrivals/proc/NukeDiskCheck()
for (var/obj/item/weapon/disk/nuclear/N in GLOB.poi_list)
if (get_area(N) in areas)
return TRUE
return FALSE
/obj/docking_port/mobile/arrivals/proc/SendToStation()
var/dockTime = config.arrivals_shuttle_dock_window
if(mode == SHUTTLE_CALL && timeLeft(1) > dockTime)
@@ -140,11 +146,17 @@
var/docked = S1 == assigned_transit
sound_played = FALSE
if(docked) //about to launch
if(!force_depart && PersonCheck())
mode = SHUTTLE_IDLE
if(console)
console.say("Launch cancelled, lifeform dectected on board.")
return
if(!force_depart)
var/cancel_reason
if(PersonCheck())
cancel_reason = "lifeform dectected on board"
else if(NukeDiskCheck())
cancel_reason = "critical station device detected on board"
if(cancel_reason)
mode = SHUTTLE_IDLE
if(console)
console.say("Launch cancelled, [cancel_reason].")
return
force_depart = FALSE
. = ..()
if(!. && !docked && !damaged)