Remaps sleepers to stasis beds and make stasis actually leave you
This commit is contained in:
@@ -152,6 +152,8 @@
|
||||
// GROUPED //
|
||||
/////////////
|
||||
|
||||
#define STASIS_MACHINE_EFFECT "stasis_machine"
|
||||
|
||||
#define STASIS_ASCENSION_EFFECT "heretic_ascension"
|
||||
|
||||
/// If the incapacitated status effect will ignore a mob in stasis (stasis beds)
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
/obj/machinery/stasis/Exited(atom/movable/AM, atom/newloc)
|
||||
if(AM == occupant)
|
||||
var/mob/living/L = AM
|
||||
if(L.IsInStasis())
|
||||
if(IS_IN_STASIS(L))
|
||||
thaw_them(L)
|
||||
. = ..()
|
||||
|
||||
@@ -95,12 +95,13 @@
|
||||
return
|
||||
var/freq = rand(24750, 26550)
|
||||
playsound(src, 'sound/effects/spray.ogg', 5, TRUE, 2, frequency = freq)
|
||||
target.SetStasis(TRUE)
|
||||
target.apply_status_effect(/datum/status_effect/grouped/stasis, STASIS_MACHINE_EFFECT)
|
||||
|
||||
target.ExtinguishMob()
|
||||
use_power = ACTIVE_POWER_USE
|
||||
|
||||
/obj/machinery/stasis/proc/thaw_them(mob/living/target)
|
||||
target.SetStasis(FALSE)
|
||||
target.remove_status_effect(/datum/status_effect/grouped/stasis, STASIS_MACHINE_EFFECT)
|
||||
if(target == occupant)
|
||||
use_power = IDLE_POWER_USE
|
||||
|
||||
@@ -124,9 +125,9 @@
|
||||
return
|
||||
var/mob/living/L_occupant = occupant
|
||||
if(stasis_running())
|
||||
if(!L_occupant.IsInStasis())
|
||||
if(!IS_IN_STASIS(L_occupant))
|
||||
chill_out(L_occupant)
|
||||
else if(L_occupant.IsInStasis())
|
||||
else if(IS_IN_STASIS(L_occupant))
|
||||
thaw_them(L_occupant)
|
||||
|
||||
/obj/machinery/stasis/screwdriver_act(mob/living/user, obj/item/I)
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
. = SEND_SIGNAL(src, COMSIG_LIVING_LIFE, seconds, times_fired)
|
||||
if(!(. & COMPONENT_INTERRUPT_LIFE_PHYSICAL))
|
||||
PhysicalLife(seconds, times_fired)
|
||||
if(!(. & COMPONENT_INTERRUPT_LIFE_BIOLOGICAL) && !IS_IN_STASIS())
|
||||
if(!(. & COMPONENT_INTERRUPT_LIFE_BIOLOGICAL) && !IS_IN_STASIS(src))
|
||||
BiologicalLife(seconds, times_fired)
|
||||
|
||||
// CODE BELOW SHOULD ONLY BE THINGS THAT SHOULD HAPPEN NO MATTER WHAT AND CAN NOT BE SUSPENDED!
|
||||
|
||||
@@ -434,7 +434,7 @@
|
||||
death()
|
||||
|
||||
/mob/living/incapacitated(ignore_restraints = FALSE, ignore_grab = FALSE, check_immobilized = FALSE, ignore_stasis = FALSE)
|
||||
if(stat || IsUnconscious() || IsStun() || IsParalyzed() || (combat_flags & COMBAT_FLAG_HARD_STAMCRIT) || (check_immobilized && IsImmobilized()) || (!ignore_restraints && restrained(ignore_grab)) || (!ignore_stasis && IS_IN_STASIS()))
|
||||
if(stat || IsUnconscious() || IsStun() || IsParalyzed() || (combat_flags & COMBAT_FLAG_HARD_STAMCRIT) || (check_immobilized && IsImmobilized()) || (!ignore_restraints && restrained(ignore_grab)) || (!ignore_stasis && IS_IN_STASIS(src)))
|
||||
return TRUE
|
||||
|
||||
/mob/living/canUseStorage()
|
||||
|
||||
Reference in New Issue
Block a user