From 249b5a904b8a23eefeadbdc5b8facfacdb8ead4a Mon Sep 17 00:00:00 2001 From: Leshana Date: Mon, 10 Apr 2017 13:01:51 -0400 Subject: [PATCH] Fix step_trigger teleporters to use forceMove() * They previously just updated your coordinates, skipping all those things which forceMove() was invented for and causing all the same problems that mob.loc = X caused. --- code/game/objects/effects/step_triggers.dm | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/code/game/objects/effects/step_triggers.dm b/code/game/objects/effects/step_triggers.dm index fa521c104a..c2fb1074b4 100644 --- a/code/game/objects/effects/step_triggers.dm +++ b/code/game/objects/effects/step_triggers.dm @@ -95,10 +95,8 @@ Trigger(var/atom/movable/A) if(teleport_x && teleport_y && teleport_z) - - A.x = teleport_x - A.y = teleport_y - A.z = teleport_z + var/turf/T = locate(teleport_x, teleport_y, teleport_z) + A.forceMove(T) /* Random teleporter, teleports atoms to locations ranging from teleport_x - teleport_x_offset, etc */ @@ -110,8 +108,5 @@ Trigger(var/atom/movable/A) if(teleport_x && teleport_y && teleport_z) if(teleport_x_offset && teleport_y_offset && teleport_z_offset) - - A.x = rand(teleport_x, teleport_x_offset) - A.y = rand(teleport_y, teleport_y_offset) - A.z = rand(teleport_z, teleport_z_offset) - + var/turf/T = locate(rand(teleport_x, teleport_x_offset), rand(teleport_y, teleport_y_offset), rand(teleport_z, teleport_z_offset)) + A.forceMove(T)