[PR #4054] [MERGED] Arrows fly on when an enderman teleports away from them #5384

Closed
opened 2026-11-03 05:12:13 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/4054
Author: @DUzzL
Created: 10/29/2026
Status: ✅ Merged
Merged: 10/29/2026
Merged by: @levzzz5154

Base: main ← Head: fix/issue-4038-enderman-arrow-teleport


📝 Commits (1)

  • 80cb00a Arrows fly on when an enderman teleports away from them

📊 Changes

3 files changed (+26 additions, -4 deletions)

View changed files

📝 crates/horizon-client/src/arrows.rs (+5 -0)
📝 crates/horizon-client/src/game/creatures.rs (+11 -1)
📝 crates/horizon-client/src/mobs/enderman.rs (+10 -3)

📄 Description

🤖 Opened by DUzzL's AI agent, not by DUzzL personally.

Fixes #4038

Cause: Enderman.hurtServer dodges projectiles by teleporting and returns true, and AbstractArrow.onHitEntity then returns early (no hit sound, no discard), so the arrow flies on and falls. Horizon refused the damage and the mob branch of the arrow handler dropped the arrow.

Change: new EntityHit::Dodged outcome that leaves the arrow untouched; the arrow handler uses it when an unseated enderman dodges (enderman::dodges).

Tested: cargo fmt --check, cargo clippy -p horizon-client --lib --bins -D warnings, cargo test -p horizon-client --lib enderman (extended unit test for dodges) pass.
Not tested: no in-game run, no parity harnesses (no vanilla data in .local). The teleport is applied on the enderman's next AI step, not instantly, and a failed teleport (all 64 tries) does not turn the arrow back.


🔄 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/4054 **Author:** [@DUzzL](https://github.com/DUzzL) **Created:** 10/29/2026 **Status:** ✅ Merged **Merged:** 10/29/2026 **Merged by:** [@levzzz5154](https://github.com/levzzz5154) **Base:** `main` ← **Head:** `fix/issue-4038-enderman-arrow-teleport` --- ### 📝 Commits (1) - [`80cb00a`](https://github.com/horizon-rust/horizon/commit/80cb00a4948f5493e599e98fb78c4c517569c6b5) Arrows fly on when an enderman teleports away from them ### 📊 Changes **3 files changed** (+26 additions, -4 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/src/arrows.rs` (+5 -0) 📝 `crates/horizon-client/src/game/creatures.rs` (+11 -1) 📝 `crates/horizon-client/src/mobs/enderman.rs` (+10 -3) </details> ### 📄 Description > 🤖 Opened by DUzzL's AI agent, not by DUzzL personally. Fixes #4038 Cause: `Enderman.hurtServer` dodges projectiles by teleporting and returns true, and `AbstractArrow.onHitEntity` then returns early (no hit sound, no discard), so the arrow flies on and falls. Horizon refused the damage and the mob branch of the arrow handler dropped the arrow. Change: new `EntityHit::Dodged` outcome that leaves the arrow untouched; the arrow handler uses it when an unseated enderman dodges (`enderman::dodges`). Tested: `cargo fmt --check`, `cargo clippy -p horizon-client --lib --bins -D warnings`, `cargo test -p horizon-client --lib enderman` (extended unit test for `dodges`) pass. Not tested: no in-game run, no parity harnesses (no vanilla data in `.local`). The teleport is applied on the enderman's next AI step, not instantly, and a failed teleport (all 64 tries) does not turn the arrow back. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 05:12:13 +07:00
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#5384
No description provided.