From f8825f17525b8fc3c3754332c0f382c931e93e57 Mon Sep 17 00:00:00 2001 From: Datraen Date: Sat, 26 Mar 2016 18:33:46 -0400 Subject: [PATCH] Fixes buckling preventing NanoUI interactions, resist unbuckling and uncuffing at the same time. --- code/modules/mob/living/carbon/resist.dm | 6 +++--- code/modules/mob/mob.dm | 4 +++- html/changelogs/Datraen-Buckle-ResistFix.yml | 7 +++++++ 3 files changed, 13 insertions(+), 4 deletions(-) create mode 100644 html/changelogs/Datraen-Buckle-ResistFix.yml diff --git a/code/modules/mob/living/carbon/resist.dm b/code/modules/mob/living/carbon/resist.dm index eb15ced89b0..07248927bd5 100644 --- a/code/modules/mob/living/carbon/resist.dm +++ b/code/modules/mob/living/carbon/resist.dm @@ -19,12 +19,12 @@ ExtinguishMob() return - ..() - - if(handcuffed) + else if(handcuffed) spawn() escape_handcuffs() else if(legcuffed) spawn() escape_legcuffs() + else + ..() /mob/living/carbon/proc/escape_handcuffs() //if(!(last_special <= world.time)) return diff --git a/code/modules/mob/mob.dm b/code/modules/mob/mob.dm index fdbb295b94e..ebb7f19ef4f 100644 --- a/code/modules/mob/mob.dm +++ b/code/modules/mob/mob.dm @@ -154,7 +154,9 @@ /mob/proc/buckled() // Preliminary work for a future buckle rewrite, // where one might be fully restrained (like an elecrical chair), or merely secured (shuttle chair, keeping you safe but not otherwise restrained from acting) - return buckled ? FULLY_BUCKLED : UNBUCKLED + if(!buckled) + return UNBUCKLED + return restrained() ? FULLY_BUCKLED : PARTIALLY_BUCKLED /mob/proc/incapacitated(var/incapacitation_flags = INCAPACITATION_DEFAULT) if (stat || paralysis || stunned || weakened || resting || sleeping || (status_flags & FAKEDEATH)) diff --git a/html/changelogs/Datraen-Buckle-ResistFix.yml b/html/changelogs/Datraen-Buckle-ResistFix.yml new file mode 100644 index 00000000000..9c2566cab0d --- /dev/null +++ b/html/changelogs/Datraen-Buckle-ResistFix.yml @@ -0,0 +1,7 @@ +author: Datraen + +delete-after: True + +changes: + - bugfix: "Fixes the buckled check limiting whether or not someone can interact while sitting." + - bugfix: "Resisting while buckled and cuffed will process the hand and leg cuffs before unbuckling."