Dynamic teleport offset. (Math Warning)

A volume that dynamically changes offset based on the location you entered the teleporter from.

Here’s a diagram to try and show what I mean: (I am neither a mathematician nor a programmer. Pardon the strange notation.)

Player p enters teleporter volume T. T has a coordinate placement of x100 y100. T’s destination d is equal to x500 y500. p first enters volume at coordinate x0 y200. This is offset from T by x-100 y+100.
When p teleports, they end up not at d, but rather , calculated using p’s original offset from T. (dx - 100 = D¹x, dy + 100 = D¹y).

p then teleports again, instead entering the volume at x25 y0. This is offset from T by x-75 y-100.
Again, instead of ending up at d, they end up at . (dx - 75 = D²x, dy + 100 = D²y).

Where p ends up is based on where p enters T volume, offset from d.

This means that the teleportation will be smoother than a teleporter that always teleports p to d.

This teleporter volume would also have an option to add or subtract rotation from the players view. Instead of setting rotation from say, 192.2 → 90, we could make it add or subtract from the angle, 192.2 + 90 = 272.2, or 192.2 - 90 = 102.2. This would also make teleportation less disorienting and smoother (give or take with ping and desync) for the person who is teleporting.

I hope my explanation wasn’t too confusing!

Me reading this:

I take it as your suggestion would, in layman’s terms, allow seamless teleportations between identically built rooms?

Yes, the best comparison I can make is like loading zones in Half-Life, If you’re on the left side of a doorframe before a loading zone, you’ll appear on the left side of the “same” doorframe in the next map.

1 Like

This is doable.

1 Like