[PR #7878] auto_jump: a player riding a vehicle never auto-jumps #7876

Open
opened 2026-11-03 07:25:51 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/7878
Author: @MSedgeMC
Created: 11/2/2026
Status: 🔄 Open

Base: main ← Head: test/auto-jump-riding


📝 Commits (2)

  • da96552 test: a player riding something never auto-jumps
  • a80520b harness: the case's rider flag reaches canAutoJump

📊 Changes

3 files changed (+38 additions, -10 deletions)

View changed files

📝 crates/horizon-client/examples/probe/auto_jump_probe.rs (+21 -8)
📝 mods/horizon/src/test/java/dev/horizonlab/parity/VanillaAutoJumpOracle.java (+3 -0)
📝 tools/test_auto_jump_parity.py (+14 -2)

📄 Description

LocalPlayer.canAutoJump refuses a passenger before it looks ahead: isPassenger() sits right after the staying-on-ground test and before the moving and block-jump-factor ones. tools/test_auto_jump_parity.py listed passenger among the preconditions it compared, but nothing ever set it: the case tuples had no such field, the Java shell answered the real isPassenger() for a player riding nothing, and MotionWorld::update_auto_jump passed a hard-coded false for the flag ("MotionWorld drives an unmounted player"). The guard could be deleted with every case still matching.

The case makes the player a passenger. 39 blocks the scene already knows are approached from 0.6 of a block away at the two step lengths the on-foot walk family jumps from, with the rest of the state (enabled, autojump time 0, on ground, not sneaking, a forward input vector) exactly the state that jumps on foot; one case in five of the random family rides as well, so riders also meet slabs, ceilings, odd sizes and jump boosts. 2,125 of the 10,646 cases are riders.

Proven:

  • python3 tools/test_auto_jump_parity.py: 10,646 auto-jump cases (1,083 jumps) match the pinned client. 78 of them are the riding family, 2,125 riders in all.
  • With && !passenger removed from can_auto_jump, 160 cases differ and every one of them is a rider; no on-foot case differs, and the 1,965 riders whose other preconditions already refuse still match. The first is case 10, a stone step 0.215 of a block ahead: vanilla jump 0, Horizon jump 1.
  • The removal was invisible before this case: the same edit against the previous corpus still reported 10,568 auto-jump cases (1,200 jumps) match the pinned client.

Not proven: the rider flag is asked of can_auto_jump in the probe, because the movement world it drives has no vehicle yet; a rider's own travel, the vehicle's motion and the minecart paths are still outside this comparison, as is the entity-collision list (the scene has no entities, and the oracle returns none).


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/horizon-rust/horizon/pull/7878 **Author:** [@MSedgeMC](https://github.com/MSedgeMC) **Created:** 11/2/2026 **Status:** 🔄 Open **Base:** `main` ← **Head:** `test/auto-jump-riding` --- ### 📝 Commits (2) - [`da96552`](https://github.com/horizon-rust/horizon/commit/da96552f1ba2df6d0c73527606a3d4c136a07f9a) test: a player riding something never auto-jumps - [`a80520b`](https://github.com/horizon-rust/horizon/commit/a80520b5463cbd57cce32b8d5cb649f852472799) harness: the case's rider flag reaches canAutoJump ### 📊 Changes **3 files changed** (+38 additions, -10 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/examples/probe/auto_jump_probe.rs` (+21 -8) 📝 `mods/horizon/src/test/java/dev/horizonlab/parity/VanillaAutoJumpOracle.java` (+3 -0) 📝 `tools/test_auto_jump_parity.py` (+14 -2) </details> ### 📄 Description `LocalPlayer.canAutoJump` refuses a passenger before it looks ahead: `isPassenger()` sits right after the staying-on-ground test and before the moving and block-jump-factor ones. `tools/test_auto_jump_parity.py` listed `passenger` among the preconditions it compared, but nothing ever set it: the case tuples had no such field, the Java shell answered the real `isPassenger()` for a player riding nothing, and `MotionWorld::update_auto_jump` passed a hard-coded `false` for the flag ("MotionWorld drives an unmounted player"). The guard could be deleted with every case still matching. The case makes the player a passenger. 39 blocks the scene already knows are approached from 0.6 of a block away at the two step lengths the on-foot walk family jumps from, with the rest of the state (enabled, autojump time 0, on ground, not sneaking, a forward input vector) exactly the state that jumps on foot; one case in five of the random family rides as well, so riders also meet slabs, ceilings, odd sizes and jump boosts. 2,125 of the 10,646 cases are riders. **Proven:** - `python3 tools/test_auto_jump_parity.py`: `10,646 auto-jump cases (1,083 jumps) match the pinned client`. 78 of them are the riding family, 2,125 riders in all. - With `&& !passenger` removed from `can_auto_jump`, 160 cases differ and every one of them is a rider; no on-foot case differs, and the 1,965 riders whose other preconditions already refuse still match. The first is case 10, a stone step 0.215 of a block ahead: vanilla `jump 0`, Horizon `jump 1`. - The removal was invisible before this case: the same edit against the previous corpus still reported `10,568 auto-jump cases (1,200 jumps) match the pinned client`. **Not proven:** the rider flag is asked of `can_auto_jump` in the probe, because the movement world it drives has no vehicle yet; a rider's own travel, the vehicle's motion and the minecart paths are still outside this comparison, as is the entity-collision list (the scene has no entities, and the oracle returns none). --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
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#7876
No description provided.