Stops buckled mobs from slipping (for now)

This commit is contained in:
Hubblenaut
2014-07-02 22:36:49 +02:00
parent abef4bf943
commit dfece9fe12
4 changed files with 11 additions and 5 deletions
+1 -1
View File
@@ -555,7 +555,7 @@ steam.start() -- spawns the effect
if (istype(AM, /mob/living/carbon))
var/mob/M = AM
if (istype(M, /mob/living/carbon/human) && (istype(M:shoes, /obj/item/clothing/shoes) && M:shoes.flags&NOSLIP))
if (istype(M, /mob/living/carbon/human) && (istype(M:shoes, /obj/item/clothing/shoes) && M:shoes.flags&NOSLIP) || M.buckled)
return
M.stop_pulling()
@@ -11,7 +11,7 @@
/obj/item/weapon/bananapeel/HasEntered(AM as mob|obj)
if (istype(AM, /mob/living/carbon))
var/mob/M = AM
if (istype(M, /mob/living/carbon/human) && (isobj(M:shoes) && M:shoes.flags&NOSLIP))
if (istype(M, /mob/living/carbon/human) && (isobj(M:shoes) && M:shoes.flags&NOSLIP) || M.buckled)
return
M.stop_pulling()
@@ -26,7 +26,7 @@
/obj/item/weapon/soap/HasEntered(AM as mob|obj) //EXACTLY the same as bananapeel for now, so it makes sense to put it in the same dm -- Urist
if (istype(AM, /mob/living/carbon))
var/mob/M = AM
if (istype(M, /mob/living/carbon/human) && (isobj(M:shoes) && M:shoes.flags&NOSLIP))
if (istype(M, /mob/living/carbon/human) && (isobj(M:shoes) && M:shoes.flags&NOSLIP) || M.buckled)
return
M.stop_pulling()
+7 -1
View File
@@ -73,6 +73,12 @@
bloodDNA = null
var/noslip = 0
for (var/obj/structure/stool/bed/chair/C in loc)
if (C.buckled_mob == M)
noslip = 1
if (noslip)
return // no slipping while sitting in a chair, plz
switch (src.wet)
if(1)
if(istype(M, /mob/living/carbon/human)) // Added check since monkeys don't have shoes
@@ -99,7 +105,7 @@
return
if(2) //lube //can cause infinite loops - needs work
if(!istype(M, /mob/living/carbon/slime))
if(!istype(M, /mob/living/carbon/slime) && !M.buckled)
M.stop_pulling()
step(M, M.dir)
spawn(1) step(M, M.dir)
@@ -731,7 +731,7 @@
/obj/item/weapon/reagent_containers/food/snacks/grown/bluetomato/HasEntered(AM as mob|obj)
if (istype(AM, /mob/living/carbon))
var/mob/M = AM
if (istype(M, /mob/living/carbon/human) && (isobj(M:shoes) && M:shoes.flags&NOSLIP))
if (istype(M, /mob/living/carbon/human) && (isobj(M:shoes) && M:shoes.flags&NOSLIP) || M.buckled)
return
M.stop_pulling()