I don't have the asgard teleporter, so I can't test whether or not I have the right answer, but I've had some experience with teleporters. I think you're on the right track. As a basic math example, let's say we have point A, which is at 0,0 and point B which is at 1,2. Point B is 1 unit farther along the X axis, and 2 points farther along on the Y axis. The way to get their difference is to subtract A from B. So, if we have our on-ship GPS device at point A, and our person at point B, we first want to calculate where the person is in relation to the GPS device. So, we get the X, Y, Z coordinates by subtracting the GPS device's coordinates from the person's coordinates. (You appear to have subtracted the person's coordinates from the GPS device's coordinates, which would be backwards.)
Now, let's say we want point B to be 2 units farther along the X axis, and 3 units farther along the Y axis, relative to point A. We would add 2 to A's X coordinate, and 3 to A's Y coordinate. So, once you get the new GPS device coordinates (or if you know them already), you add that original difference in location to the new location. In other words, if the person was 5 units away from the GPS device on the X axis, you now position them 5 units away from the new GPS device location on the X axis.
If I were to write an expression to do this, it would look like this:
N@matter converters
I@GX GY GZ TX TY TZ LX LY LZ Save
O@X Y Z
Save == 0 -> X = TX - GX + LX
Save == 0 -> Y = TY - GY + LY
Save == 0 -> Z = TZ - GZ + LZ
Assuming LX is how much you're changing your ship's X coordinate, assuming you calculate this before the ship teleports and save it (by setting Save to equal anything other than 0 immediately before you teleport), and assuming the GPS device is on the ship. My suspicion, since you say the person ended up beneath a planet or something, is that you teleported and then made this calculation. If it was only a problem of mixing up the order in which you should subtract, the person would have ended up on the exact opposite side of the GPS device, but no further away from it. If you mess up both of these, first the ship teleports, and then you end up on the opposite side of the GPS device on the ship but at the same distance, which would send you far away.


LinkBack URL
About LinkBacks




Reply With Quote
Bookmarks