Ghosting refactor (#32855)

Co-authored-by: kanef <kanef9x@protonmail.com>
This commit is contained in:
kane-f
2022-07-04 21:07:21 +01:00
committed by GitHub
parent aa709c6564
commit f5322d18d5
7 changed files with 37 additions and 45 deletions

View File

@@ -432,6 +432,12 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
ghostize(1)
else if(stat == DEAD)
ghostize(1)
else if(check_rights(R_ADMIN))
if(mind)
mind.isScrying = 1
ghostize(1)
if(!key)
key = "@[key]" //Haaaaaaaack. But the people have spoken. If it breaks; blame adminbus
else
var/response = alert(src, "Are you -sure- you want to ghost?\n(You are alive. If you ghost, you will not be able to re-enter your current body! You can't change your mind so choose wisely!)","Are you sure you want to ghost?","Ghost","Stay in body")
if(response != "Ghost")

View File

@@ -1,8 +1,16 @@
/mob/dead/observer/verb/ghost()
set category = "OOC"
set name = "Ghost"
reenter_corpse()
/mob/dead/observer/verb/reenter_corpse()
set category = "Ghost"
set name = "Re-enter Corpse"
var/mob/M = get_top_transmogrification()
if(check_rights(R_ADMIN)) // admins
can_reenter_corpse = 1 //just in-case.
if(!M.client)
return
if(!(mind && mind.current && can_reenter_corpse))
@@ -547,7 +555,7 @@
var/response = alert(src, "Are you -sure- you want to become a space hobo?","Are you sure you want to ramble?","Yeah!","Nope!")
if(response != "Yeah!" || !src.key)
return //Hit the wrong key...again.
var/mob/living/carbon/human/hobo = new(pick(hobostart))
hobo.key = src.key
hobo.set_species(pick(200;"Human",50;"Vox",50;"Insectoid",25;"Diona",25;"Grey",1;"Tajaran",10;"Unathi"))