From c7eb8b430d214c7dbca5f9a07f8ebb74a2d758b7 Mon Sep 17 00:00:00 2001 From: Detective Google <48196179+Detective-Google@users.noreply.github.com> Date: Fri, 6 Mar 2020 23:22:41 -0600 Subject: [PATCH] adds the option for AIs to cryo without being dragged and stuffed in a pod on the other side of the station. --- code/modules/mob/living/silicon/ai/ai.dm | 25 ++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/code/modules/mob/living/silicon/ai/ai.dm b/code/modules/mob/living/silicon/ai/ai.dm index 703e5cefac..7f0d24e199 100644 --- a/code/modules/mob/living/silicon/ai/ai.dm +++ b/code/modules/mob/living/silicon/ai/ai.dm @@ -1004,3 +1004,28 @@ . = ..() if(.) end_multicam() + +/mob/living/silicon/ai/verb/ai_cryo() + set name = "AI Cryogenic Stasis" + set desc = "Puts the current AI personality into cryogenic stasis, freeing the space for another." + set category = "AI Commands" + + if(incapacitated()) + return + switch(alert("Would you like to enter cryo? This will ghost you. Remember to AHELP before cryoing out of important roles, even with no admins online.",,"Yes.","No.")) + if("Yes.") + src.ghostize(FALSE, penalize = TRUE) + var/announce_rank = "Artificial Intelligence," + if(GLOB.announcement_systems.len) + // Sends an announcement the AI has cryoed. + var/obj/machinery/announcement_system/announcer = pick(GLOB.announcement_systems) + announcer.announce("CRYOSTORAGE", src.real_name, announce_rank, list()) + new /obj/structure/AIcore/latejoin_inactive(loc) + if(src.mind) + //Handle job slot/tater cleanup. + if(src.mind.assigned_role) + SSjob.FreeRole("AI") + src.mind.special_role = null + qdel(src) + else + return