Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Teleport is to one Corner of the new Block, not the Center #3

Closed
toydotgame opened this issue Dec 28, 2020 · 1 comment
Closed

Teleport is to one Corner of the new Block, not the Center #3

toydotgame opened this issue Dec 28, 2020 · 1 comment
Assignees
Labels
bug Something isn't working done

Comments

@toydotgame
Copy link
Owner

toydotgame commented Dec 28, 2020

When Thisway is used, the plugin ignores current player position exacts.

Example:

2020-12-29_08 15 35
The player is at coordinates (X, Y, Z): 1417.50000, 80.000, 1483.50000
The player's yaw is ~0.5. This is SOUTH.

When the command is run to go forward one block,
2020-12-29_08 15 39
...the coordinates are approximated.
Debug output will show initial player coordinates (To the plugin) as: 1417, 80, 1483
Thisway is assuming that instead of [relative coordinates] being (X, Z (Relative)): ~.5, ~.5
...That the plugin ignores precision and goes with 0 as the precise decimal coordinate, thus (X, Z (Relative)): ~.0, ~.0

Possible solutions:

Either:

  1. Make the plugin teleport the player to (X, Y, Z (Relative to new TP location)): ~.5, ~, ~.5. Instead of ~.0, ~.0, ~.0. This will make the new TP location in the center of the new block.
  2. Make Bukkit/Spigot understand the precise coordinates when modifying them to teleport. This way, teleporting from somewhere which is not (relatively) ~.0, ~.0, ~.0 - will teleport to the same precise coordinate. i.e: Teleporting from 189.51, 90, 194.58 will preserve the decimals in the coordinate, making the player's new relative coordinates still ~.51, ~, ~.58.
@toydotgame toydotgame self-assigned this Dec 28, 2020
@toydotgame toydotgame added bug Something isn't working good first issue willfix This will be worked on labels Dec 28, 2020
@toydotgame
Copy link
Owner Author

This will be addressed in update 1.1. Expect commits soon.

toydotgame added a commit that referenced this issue Dec 28, 2020
@toydotgame toydotgame added done and removed willfix This will be worked on labels Mar 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working done
Projects
None yet
Development

No branches or pull requests

1 participant