From bce6e5594ef74ceb1af129ab3a1917752f6315bc Mon Sep 17 00:00:00 2001 From: ShizCalev Date: Wed, 31 Oct 2018 12:41:43 -0400 Subject: [PATCH] Canusetopic fix --- code/modules/mob/living/carbon/carbon.dm | 1 + code/modules/mob/living/living.dm | 9 +++++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm index e7364e2840a..df5a4a85aec 100644 --- a/code/modules/mob/living/carbon/carbon.dm +++ b/code/modules/mob/living/carbon/carbon.dm @@ -783,6 +783,7 @@ update_action_buttons_icon() //some of our action buttons might be unusable when we're handcuffed. update_inv_handcuffed() update_hud_handcuffed() + update_mobility() /mob/living/carbon/fully_heal(admin_revive = FALSE) if(reagents) diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm index a3b837b28b0..42b3513743b 100644 --- a/code/modules/mob/living/living.dm +++ b/code/modules/mob/living/living.dm @@ -981,6 +981,7 @@ var/stat_conscious = (stat == CONSCIOUS) || stat_softcrit var/conscious = !IsUnconscious() && stat_conscious && !has_trait(TRAIT_DEATHCOMA) var/chokehold = pulledby && pulledby.grab_state >= GRAB_NECK + var/restrained = restrained() var/has_legs = get_num_legs() var/has_arms = get_num_arms() var/paralyzed = IsParalyzed() @@ -996,13 +997,17 @@ var/canstand = canstand_involuntary && !resting if(canstand) - mobility_flags |= (MOBILITY_STAND | MOBILITY_UI | MOBILITY_PULL) + mobility_flags |= MOBILITY_STAND lying = 0 + if(!restrained) + mobility_flags |= (MOBILITY_UI | MOBILITY_PULL) + else + mobility_flags &= ~(MOBILITY_UI | MOBILITY_PULL) else mobility_flags &= ~(MOBILITY_STAND | MOBILITY_UI | MOBILITY_PULL) if(!lying) lying = pick(90, 270) - var/canitem = !paralyzed && !stun && conscious && !chokehold && has_arms + var/canitem = !paralyzed && !stun && conscious && !chokehold && !restrained && has_arms if(canitem) mobility_flags |= (MOBILITY_USE | MOBILITY_PICKUP | MOBILITY_STORAGE) else