Merge pull request #5476 from Hubblenaut/wheelchair

Wheelchair Fixes
This commit is contained in:
Zuhayr
2014-07-03 13:16:14 +09:30
16 changed files with 102 additions and 41 deletions
@@ -112,7 +112,7 @@
return
//BubbleWrap: people in handcuffs are always switched around as if they were on 'help' intent to prevent a person being pulled from being seperated from their puller
if((tmob.a_intent == "help" || tmob.restrained()) && (a_intent == "help" || src.restrained()) && tmob.canmove && canmove) // mutual brohugs all around!
if((tmob.a_intent == "help" || tmob.restrained()) && (a_intent == "help" || src.restrained()) && tmob.canmove && !tmob.buckled && canmove) // mutual brohugs all around!
var/turf/oldloc = loc
loc = tmob.loc
tmob.loc = oldloc
@@ -35,7 +35,7 @@
else if(E.status & ORGAN_BROKEN)
tally += 1.5
if(pulledby && istype(pulledby, /obj/structure/stool/bed/chair/wheelchair))
if(buckled && istype(buckled, /obj/structure/stool/bed/chair/wheelchair))
for(var/organ_name in list("l_hand","r_hand","l_arm","r_arm"))
var/datum/organ/external/E = get_organ(organ_name)
if(!E || (E.status & ORGAN_DESTROYED))
+3 -3
View File
@@ -755,7 +755,7 @@ note dizziness decrements automatically in the mob's Life() proc.
//Updates canmove, lying and icons. Could perhaps do with a rename but I can't think of anything to describe it.
/mob/proc/update_canmove()
if(buckled)
if(buckled && (!buckled.movable))
anchored = 1
canmove = 0
if( istype(buckled,/obj/structure/stool/bed/chair) )
@@ -778,9 +778,9 @@ note dizziness decrements automatically in the mob's Life() proc.
anchored = 1
canmove = 0
lying = 0
else
else if (!buckled)
lying = !can_stand
canmove = has_limbs
//canmove = has_limbs
if(lying)
density = 0
+3 -4
View File
@@ -199,8 +199,7 @@
if(!mob.canmove)
if (mob.buckled && (istype(mob.buckled, /obj/structure/stool/bed/chair/wheelchair) || istype(mob.buckled, /obj/vehicle))) // Exception for wheelchairs
else return
return
//if(istype(mob.loc, /turf/space) || (mob.flags & NOGRAV))
// if(!mob.Process_Spacemove(0)) return 0
@@ -246,7 +245,7 @@
move_delay -= 1.3
var/tickcomp = ((1/(world.tick_lag))*1.3)
move_delay = move_delay + tickcomp
if(istype(mob.buckled, /obj/vehicle))
return mob.buckled.relaymove(mob,direct)
@@ -260,7 +259,7 @@
var/mob/living/carbon/human/driver = mob.buckled
var/datum/organ/external/l_hand = driver.get_organ("l_hand")
var/datum/organ/external/r_hand = driver.get_organ("r_hand")
if((!l_hand || l_hand.status & ORGAN_DESTROYED) && (!r_hand || r_hand.status & ORGAN_DESTROYED))
if((!l_hand || (l_hand.status & ORGAN_DESTROYED)) && (!r_hand || (r_hand.status & ORGAN_DESTROYED)))
return // No hands to drive your chair? Tough luck!
move_delay += 2
return mob.buckled.relaymove(mob,direct)