diff --git a/code/modules/mob/living/living_movement.dm b/code/modules/mob/living/living_movement.dm index fcab9344d9..31dcf6063f 100644 --- a/code/modules/mob/living/living_movement.dm +++ b/code/modules/mob/living/living_movement.dm @@ -12,10 +12,7 @@ if(combat_flags & COMBAT_FLAG_ACTIVE_BLOCKING) animate(src, pixel_x = get_standard_pixel_x_offset(), pixel_y = get_standard_pixel_y_offset(), time = 2.5, flags = ANIMATION_END_NOW) else if(moved) - if(is_shifted) - is_shifted = FALSE - pixel_x = get_standard_pixel_x_offset(lying) - pixel_y = get_standard_pixel_y_offset(lying) + unpixel_shift() /mob/living/proc/update_density() density = !lying && !HAS_TRAIT(src, TRAIT_LIVING_NO_DENSITY) diff --git a/modular_sand/code/modules/pixel_shift/pixel_shift.dm b/modular_sand/code/modules/pixel_shift/pixel_shift.dm index 253ab050f3..5b96eb1568 100644 --- a/modular_sand/code/modules/pixel_shift/pixel_shift.dm +++ b/modular_sand/code/modules/pixel_shift/pixel_shift.dm @@ -91,9 +91,15 @@ if(pixel_x < -PASSABLE_SHIFT_THRESHOLD) passthroughable |= NORTH | EAST | SOUTH +/mob/living/Login() + . = ..() + if(is_shifted) + client?.pixel_x = pixel_x - base_pixel_x + client?.pixel_y = pixel_y - base_pixel_y + /mob/living/CanAllowThrough(atom/movable/mover, turf/target) // Make sure to not allow projectiles of any kind past where they normally wouldn't. - if(!istype(mover, /obj/item/projectile) && !mover.throwing && passthroughable & mover.dir) + if(!istype(mover, /obj/item/projectile) && !mover.throwing && passthroughable & get_dir(src, mover)) return TRUE return ..()