better
This commit is contained in:
@@ -665,6 +665,7 @@
|
||||
var/puddle_icon = 'icons/mob/mob.dmi'
|
||||
var/puddle_state = "puddle"
|
||||
var/tracked_overlay
|
||||
var/datum/component/squeak/squeak
|
||||
|
||||
/datum/action/innate/slime_puddle/Activate()
|
||||
if(isjellyperson(owner))
|
||||
@@ -682,7 +683,8 @@
|
||||
ADD_TRAIT(H, TRAIT_PASSTABLE, "SLIME_PUDDLE_TABLE_PASS")
|
||||
ADD_TRAIT(H, TRAIT_SPRINT_LOCKED, "SLIME_PUDDLE_SPRINT_LOCK")
|
||||
ADD_TRAIT(H, TRAIT_COMBAT_MODE_LOCKED, "SLIME_PUDDLE_COMBAT_LOCK")
|
||||
ADD_TRAIT(H, TRAIT_REST_LOCKED, "SLIME_PUDDLE_CANNOT_STAND")
|
||||
ADD_TRAIT(H, TRAIT_MOBILITY_NOSTAND, "SLIME_PUDDLE_CANNOT_STAND")
|
||||
squeak = H.AddComponent(/datum/component/squeak, custom_sounds = list('sound/effects/blobattack.ogg'))
|
||||
sleep(in_transformation_duration)
|
||||
var/mutable_appearance/puddle_overlay = mutable_appearance(icon = puddle_icon, icon_state = puddle_state)
|
||||
puddle_overlay.color = mutcolor
|
||||
@@ -699,8 +701,10 @@
|
||||
REMOVE_TRAIT(H, TRAIT_PASSTABLE, "SLIME_PUDDLE_TABLE_PASS")
|
||||
REMOVE_TRAIT(H, TRAIT_SPRINT_LOCKED, "SLIME_PUDDLE_SPRINT_LOCK")
|
||||
REMOVE_TRAIT(H, TRAIT_COMBAT_MODE_LOCKED, "SLIME_PUDDLE_COMBAT_LOCK")
|
||||
REMOVE_TRAIT(H, TRAIT_REST_LOCKED, "SLIME_PUDDLE_CANNOT_STAND")
|
||||
REMOVE_TRAIT(H, TRAIT_MOBILITY_NOSTAND, "SLIME_PUDDLE_CANNOT_STAND")
|
||||
is_puddle = FALSE
|
||||
if(squeak)
|
||||
squeak.RemoveComponent()
|
||||
owner.regenerate_icons()
|
||||
|
||||
///////////////////////////////////LUMINESCENTS//////////////////////////////////////////
|
||||
|
||||
@@ -5,17 +5,17 @@
|
||||
RegisterSignal(src, SIGNAL_TRAIT(TRAIT_MOBILITY_NOMOVE), .proc/update_mobility)
|
||||
RegisterSignal(src, SIGNAL_TRAIT(TRAIT_MOBILITY_NOPICKUP), .proc/update_mobility)
|
||||
RegisterSignal(src, SIGNAL_TRAIT(TRAIT_MOBILITY_NOUSE), .proc/update_mobility)
|
||||
RegisterSignal(src, SIGNAL_TRAIT(TRAIT_MOBILITY_NOSTAND), .proc/update_mobility)
|
||||
|
||||
//Stuff like mobility flag updates, resting updates, etc.
|
||||
|
||||
//Force-set resting variable, without needing to resist/etc.
|
||||
/mob/living/proc/set_resting(new_resting, silent = FALSE, updating = TRUE)
|
||||
if(!HAS_TRAIT(src, TRAIT_REST_LOCKED))
|
||||
if(new_resting != resting)
|
||||
resting = new_resting
|
||||
if(!silent)
|
||||
to_chat(src, "<span class='notice'>You are now [resting? "resting" : "getting up"].</span>")
|
||||
update_resting(updating)
|
||||
if(new_resting != resting)
|
||||
resting = new_resting
|
||||
if(!silent)
|
||||
to_chat(src, "<span class='notice'>You are now [resting? "resting" : "getting up"].</span>")
|
||||
update_resting(updating)
|
||||
|
||||
/mob/living/proc/update_resting(update_mobility = TRUE)
|
||||
if(update_mobility)
|
||||
@@ -85,7 +85,7 @@
|
||||
else
|
||||
mobility_flags &= ~MOBILITY_RESIST
|
||||
|
||||
var/canstand_involuntary = conscious && !stat_softcrit && !knockdown && !chokehold && !paralyze && (ignore_legs || has_legs) && !(buckled && buckled.buckle_lying) && !(combat_flags & COMBAT_FLAG_HARD_STAMCRIT)
|
||||
var/canstand_involuntary = conscious && !stat_softcrit && !knockdown && !chokehold && !paralyze && (ignore_legs || has_legs) && !(buckled && buckled.buckle_lying) && !(combat_flags & COMBAT_FLAG_HARD_STAMCRIT) && !(HAS_TRAIT(src, TRAIT_MOBILITY_NOSTAND))
|
||||
var/canstand = canstand_involuntary && !resting
|
||||
|
||||
var/should_be_lying = !canstand
|
||||
|
||||
Reference in New Issue
Block a user