diff --git a/code/game/machinery/teleporter.dm b/code/game/machinery/teleporter.dm index 5e3c4b75f33..9ae9abe6249 100644 --- a/code/game/machinery/teleporter.dm +++ b/code/game/machinery/teleporter.dm @@ -403,7 +403,7 @@ if(!calibrated && com.cc_beacon) visible_message("Cannot lock on target. Please calibrate the teleporter before attempting long range teleportation.") else if(!calibrated && prob(25 - ((accurate) * 10)) && !com.cc_beacon) //oh dear a problem - var/list/target_z = levels_by_trait(REACHABLE) + var/list/target_z = levels_by_trait(SPAWN_RUINS) target_z -= M.z //Where to sir? Anywhere but here. . = do_teleport(M, locate(rand((2*TRANSITIONEDGE), world.maxx - (2*TRANSITIONEDGE)), rand((2*TRANSITIONEDGE), world.maxy - (2*TRANSITIONEDGE)), pick(target_z)), 2, bypass_area_flag = com.area_bypass) else diff --git a/code/game/objects/effects/portals.dm b/code/game/objects/effects/portals.dm index a2b084463a4..977b4a2a2aa 100644 --- a/code/game/objects/effects/portals.dm +++ b/code/game/objects/effects/portals.dm @@ -101,7 +101,9 @@ if(prob(failchance)) icon_state = fail_icon - if(!do_teleport(M, locate(rand(5, world.maxx - 5), rand(5, world.maxy -5), 3), 0, bypass_area_flag = ignore_tele_proof_area_setting)) // Try to send them to deep space. + var/list/target_z = levels_by_trait(SPAWN_RUINS) + target_z -= M.z + if(!do_teleport(M, locate(rand(5, world.maxx - 5), rand(5, world.maxy -5), pick(target_z)), 0, bypass_area_flag = ignore_tele_proof_area_setting)) // Try to send them to deep space. invalid_teleport() return FALSE else