mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-08-28 22:48:38 +01:00
Merge pull request #5021 from Heroman3003/steppy-steppy-on-the-meow
Fixes step code, again
This commit is contained in:
@@ -149,6 +149,12 @@ default behaviour is:
|
||||
tmob.forceMove(oldloc)
|
||||
now_pushing = 0
|
||||
return
|
||||
//VOREStation Edit - Begin
|
||||
else if((tmob.mob_always_swap || (tmob.a_intent == I_HELP || tmob.restrained()) && (a_intent == I_HELP || src.restrained())) && canmove && can_swap && handle_micro_bump_helping(tmob))
|
||||
forceMove(tmob.loc)
|
||||
now_pushing = 0
|
||||
return
|
||||
//VOREStation Edit - End
|
||||
|
||||
if(!can_move_mob(tmob, 0, 0))
|
||||
now_pushing = 0
|
||||
|
||||
@@ -155,21 +155,6 @@ var/const/RESIZE_A_SMALLTINY = (RESIZE_SMALL + RESIZE_TINY) / 2
|
||||
* @return false if normal code should continue, true to prevent normal code.
|
||||
*/
|
||||
/mob/living/proc/handle_micro_bump_helping(var/mob/living/tmob)
|
||||
//Make sure we would be able to step there in the first place:
|
||||
var/can_move_into = 1
|
||||
if(tmob.loc.density)
|
||||
can_move_into = 0
|
||||
if(can_move_into)
|
||||
for(var/atom/movable/A in tmob.loc)
|
||||
if(A == src)
|
||||
continue
|
||||
if(!A.CanPass(src, tmob.loc))
|
||||
can_move_into = 0
|
||||
if(!can_move_into) break
|
||||
|
||||
if(!can_move_into)
|
||||
return FALSE
|
||||
|
||||
//Both small! Go ahead and go.
|
||||
if(src.get_effective_size() <= RESIZE_A_SMALLTINY && tmob.get_effective_size() <= RESIZE_A_SMALLTINY)
|
||||
return TRUE
|
||||
@@ -212,21 +197,6 @@ var/const/RESIZE_A_SMALLTINY = (RESIZE_SMALL + RESIZE_TINY) / 2
|
||||
/mob/living/proc/handle_micro_bump_other(var/mob/living/tmob)
|
||||
ASSERT(istype(tmob))
|
||||
|
||||
//Can we even step on their tile normally?
|
||||
var/can_move_into = 1
|
||||
if(tmob.loc.density)
|
||||
can_move_into = 0
|
||||
if(can_move_into)
|
||||
for(var/atom/movable/A in tmob.loc)
|
||||
if(A == src)
|
||||
continue
|
||||
if(!A.CanPass(src, tmob.loc))
|
||||
can_move_into = 0
|
||||
if(!can_move_into) break
|
||||
|
||||
if(!can_move_into)
|
||||
return FALSE
|
||||
|
||||
//If they're flying, don't do any special interactions.
|
||||
if(ishuman(src))
|
||||
var/mob/living/carbon/human/P = src
|
||||
|
||||
Reference in New Issue
Block a user