mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-23 03:57:13 +01:00
Merge pull request #10778 from MINIMAN10000/helpful-push
Mobs on help intent no longer push structures or mobs that are pulling structures
This commit is contained in:
@@ -80,6 +80,10 @@
|
||||
if(moving_diagonally) //no mob swap during diagonal moves.
|
||||
return 1
|
||||
|
||||
if(a_intent == INTENT_HELP) // Help intent doesn't mob swap a mob pulling a structure
|
||||
if(isstructure(M.pulling) || isstructure(pulling))
|
||||
return 1
|
||||
|
||||
if(!M.buckled && !M.has_buckled_mobs())
|
||||
var/mob_swap
|
||||
//the puller can always swap with it's victim if on grab intent
|
||||
@@ -128,6 +132,13 @@
|
||||
|
||||
//Called when we want to push an atom/movable
|
||||
/mob/living/proc/PushAM(atom/movable/AM, force = move_force)
|
||||
|
||||
if(isstructure(AM) && AM.pulledby)
|
||||
if(a_intent == INTENT_HELP && AM.pulledby != src) // Help intent doesn't push other peoples pulled structures
|
||||
return FALSE
|
||||
if(get_dist(get_step(AM, get_dir(src, AM)), AM.pulledby)>1)//Release pulled structures beyond 1 distance
|
||||
AM.pulledby.stop_pulling()
|
||||
|
||||
if(now_pushing)
|
||||
return TRUE
|
||||
if(moving_diagonally) // no pushing during diagonal moves
|
||||
|
||||
Reference in New Issue
Block a user