Skip to content

Commit

Permalink
Merge pull request #18491 from comma/hazards
Browse files Browse the repository at this point in the history
Makes teleporter mishaps not mess with Z that much
  • Loading branch information
PsiOmegaDelta authored Sep 13, 2017
2 parents 5b03f34 + 294a57a commit c2e0e22
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions code/game/machinery/teleporter.dm
Original file line number Diff line number Diff line change
Expand Up @@ -206,9 +206,9 @@
O.show_message("<span class='warning'>Failure: Cannot authenticate locked on coordinates. Please reinstate coordinate matrix.</span>")
return
if (istype(M, /atom/movable))
if(prob(5) && !accurate) //oh dear a problem, put em in deep space
if(prob(5) && !accurate) //oh dear a problem
var/turf/T = get_turf(M)
var/destination_z = T ? GLOB.using_map.get_transit_zlevel(T.z) : pick(GLOB.using_map.player_levels)
var/destination_z = T ? GetConnectedZlevels(T.z) : GetConnectedZlevels(z)
do_teleport(M, locate(rand((2*TRANSITIONEDGE), world.maxx - (2*TRANSITIONEDGE)), rand((2*TRANSITIONEDGE), world.maxy - (2*TRANSITIONEDGE)), destination_z), 2)
else
do_teleport(M, com.locked) //dead-on precision
Expand Down

0 comments on commit c2e0e22

Please sign in to comment.