Respawning using anomalous crystal exploit fixes (#16165)

* Ahud anomalous crystal fix
Makes it so that you can't get around ahud enabling using the anomalous helper crystal

* Merge conflict fix thing
This commit is contained in:
Farie82
2021-06-12 19:13:42 +02:00
committed by GitHub
parent ddacfbb009
commit 7f6a28f16d

View File

@@ -231,12 +231,22 @@
/obj/machinery/anomalous_crystal/helpers/attack_ghost(mob/dead/observer/user)
..()
if(cannotPossess(user))
return
if(ready_to_deploy)
if(!istype(user)) // No revs allowed
return
if(cannotPossess(user))
to_chat(user, "<span class='warning'>Upon using the antagHUD you forfeited the ability to join the round.</span>")
return
if(!user.can_reenter_corpse)
to_chat(user, "<span class='warning'>You have forfeited the right to respawn.</span>")
return
var/be_helper = alert("Become a Lightgeist? (Warning, You can no longer be cloned!)",,"Yes","No")
if(be_helper == "No")
return
if(!loc || QDELETED(src) || QDELETED(user))
if(user)
to_chat(user, "<span class='warning'>[src] is no longer usable!</span>")
return
var/mob/living/simple_animal/hostile/lightgeist/W = new /mob/living/simple_animal/hostile/lightgeist(get_turf(loc))
W.key = user.key