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 de-sync #363

Open
1 task done
Alvsch opened this issue Dec 1, 2024 · 4 comments
Open
1 task done

Teleport de-sync #363

Alvsch opened this issue Dec 1, 2024 · 4 comments
Assignees
Labels
bug Something isn't working

Comments

@Alvsch
Copy link
Contributor

Alvsch commented Dec 1, 2024

I've searched existing issues and couldn't find a duplicate.

  • I confirm this is not a duplicate.

Operating System

Manjaro Linux

Server Software Version/Commit

f29cfbc

What happened?

Player position gets de-synced between clients when teleporting more than 8 blocks. This results in the player falling through the ground on other players POV.

To Reproduce

/teleport ~ ~10 ~
You should then be in the ground for other players when falling to the ground.

Expected behavior

Teleport 10 blocks up and then fall down stopping at the ground for all players.

@Alvsch Alvsch added the bug Something isn't working label Dec 1, 2024
@Commandcracker
Copy link
Contributor

Can confirm 👍

@DataM0del
Copy link
Contributor

I think I've had this months ago.

@Snowiiii Snowiiii added this to Pumpkin Dec 7, 2024
@Snowiiii Snowiiii moved this to Todo Bugs in Pumpkin Dec 7, 2024
Snowiiii added a commit that referenced this issue Dec 7, 2024
@Snowiiii
Copy link
Member

Snowiiii commented Dec 7, 2024

I think it is because of the relative PositionFlags which are not being send (we just use an empty array)

@Snowiiii Snowiiii added the good first issue Good for newcomers label Dec 22, 2024
@Witcher01
Copy link

@Snowiiii I don't think that's the case:

In the lower 8 bits of the bit field, a set bit means the teleportation on the corresponding axis is relative, and an unset bit that it is absolute.

https://minecraft.wiki/w/Minecraft_Wiki:Projects/wiki.vg_merge/Protocol#Teleport_Flags

Not setting any bits there means the teleportation is absolute, not relative. The teleportation itself works because the coordinates always seem to be given as absolute ones. All argument consumers used for teleporation with positions are Position3DArgumentConsumers, which convert the relative position to an absolute one when the arguments are parsed in the dispatcher. Given that teleporting works in principal, even with relative coordinates, this shouldn't be the issue from what I can see.

Setting some of the bits didn't solve the issue for me, either.

I think it's fair to remove the "good first issue" label from this one.

@Snowiiii Snowiiii removed the good first issue Good for newcomers label Jan 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants