[GH-ISSUE #3666] Controller movement on servers: analog stick moves the player in ways the server can't predict #1045

Closed
opened 2026-11-02 15:43:51 +07:00 by bsakaguchi · 0 comments
Owner

Originally created by @martipops on GitHub (Oct 29, 2026).
Original GitHub issue: https://github.com/horizon-rust/horizon/issues/3666

🤖 Filed by martipops's AI agent (Claude Code), not by martipops themselves.

Controller movement on servers: the analog stick moves the player in ways the server can't predict.

Horizon's controller movement is analog (docs/controllers.md): the left stick's direction and tilt feed the move vector directly, so a player can walk at any angle and any speed. Java Edition's client sends the server only the movement keys (ServerboundPlayerInputPacket: forward/back/left/right/jump/sneak/sprint), and vanilla's own client moves exactly as those keys do (KeyboardInput.tick: 8 directions at full speed).

On another server, the player's real motion therefore disagrees with what the keys imply. A server or anticheat that predicts movement from the keys (as many public servers' do) sees a player moving at an angle or speed the keys can't produce, and can pull it back or flag it.

Proposal: on a server that isn't this game's own server thread (multiplayer, a LAN world joined as a guest, a friend's invite), make the stick move as the keys it sets do: 8 directions, full speed. Keep analog movement in single player and on the game's own server thread, where nothing predicts it.

Fix: #3669 (on its own, small). The same change is also in #3541 (splitscreen), where it came from; it drops out of that PR once #3669 merges.

Originally created by @martipops on GitHub (Oct 29, 2026). Original GitHub issue: https://github.com/horizon-rust/horizon/issues/3666 > 🤖 Filed by martipops's AI agent (Claude Code), not by martipops themselves. **Controller movement on servers: the analog stick moves the player in ways the server can't predict.** Horizon's controller movement is analog (`docs/controllers.md`): the left stick's direction and tilt feed the move vector directly, so a player can walk at any angle and any speed. Java Edition's client sends the server only the movement *keys* (`ServerboundPlayerInputPacket`: forward/back/left/right/jump/sneak/sprint), and vanilla's own client moves exactly as those keys do (`KeyboardInput.tick`: 8 directions at full speed). On another server, the player's real motion therefore disagrees with what the keys imply. A server or anticheat that predicts movement from the keys (as many public servers' do) sees a player moving at an angle or speed the keys can't produce, and can pull it back or flag it. **Proposal:** on a server that isn't this game's own server thread (multiplayer, a LAN world joined as a guest, a friend's invite), make the stick move as the keys it sets do: 8 directions, full speed. Keep analog movement in single player and on the game's own server thread, where nothing predicts it. Fix: #3669 (on its own, small). The same change is also in #3541 (splitscreen), where it came from; it drops out of that PR once #3669 merges.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
horizon-rust/horizon#1045
No description provided.