Merge pull request #9159 from MINIMAN10000/pod-eject

Restrained spacepod passenger can now exit pod after 2 minutes
This commit is contained in:
Crazy Lemon
2018-07-03 12:05:04 -07:00
committed by GitHub
+8 -1
View File
@@ -812,11 +812,18 @@ obj/spacepod/proc/add_equipment(mob/user, var/obj/item/spacepod_equipment/SPE, v
if(!istype(user))
return
if(usr.incapacitated()) // unconscious and restrained people can't let themselves out
if(usr.stat != CONSCIOUS) // unconscious people can't let themselves out
return
occupant_sanity_check()
if(usr.restrained())
to_chat(usr, "<span class='notice'>You attempt to stumble out of the [src]. This will take two minutes.</span>")
if(pilot)
to_chat(pilot, "<span class='warning'>[usr] is trying to escape the [src].</span>")
if(!do_after(usr, 1200, target = src))
return
if(user == pilot)
user.forceMove(get_turf(src))
pilot = null