[PR #6977] [MERGED] Fix dragon contacts with living mobs and show breath cloud hitboxes #7248

Closed
opened 2026-11-03 06:36:23 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/6977
Author: @AltMugen
Created: 11/2/2026
Status: ✅ Merged
Merged: 11/2/2026
Merged by: @ludovic111

Base: main ← Head: fix/dragon-living-contacts


📝 Commits (5)

  • 670350d Fix dragon contacts with living mobs and revenge target lookup
  • 100d494 Merge remote-tracking branch 'origin/main' into fix/dragon-living-contacts
  • 4d2bde9 Show synced area effect cloud hitboxes in F3+B
  • f279047 Clarify Rust damage-handler documentation for port ledger
  • 715dd98 Merge main into #6977

📊 Changes

15 files changed (+461 additions, -4 deletions)

View changed files

📝 crates/horizon-client/examples/probe/mob_ai_probe.rs (+1 -0)
📝 crates/horizon-client/src/game/command_harness.rs (+6 -0)
📝 crates/horizon-client/src/game/creatures.rs (+2 -0)
📝 crates/horizon-client/src/game/debug_keys.rs (+5 -0)
📝 crates/horizon-client/src/game/dragon.rs (+50 -0)
📝 crates/horizon-client/src/game/remote_projectiles.rs (+2 -2)
📝 crates/horizon-client/src/mobs.rs (+4 -1)
➕ crates/horizon-client/src/mobs/dragon_contacts.rs (+181 -0)
📝 crates/horizon-client/src/mobs/living.rs (+2 -0)
📝 crates/horizon-client/src/mobs/world.rs (+6 -0)
📝 crates/horizon-client/src/mobs/zombie_villager.rs (+1 -0)
📝 mods/horizon/src/test/java/dev/horizonlab/parity/VanillaCommandExecOracle.java (+10 -0)
➕ mods/horizon/src/test/java/dev/horizonlab/parity/VanillaDragonContactsOracle.java (+76 -0)
📝 tools/port_map/game2-001.tsv (+1 -1)
➕ tools/test_dragon_contacts_parity.py (+114 -0)

📄 Description

🤖 Opened by AltMugen's AI agent (Codex), not by AltMugen personally.

Summary

  • Apply dragon wing/head/neck contacts to living mobs as well as players. Preserve sitting-wing push without damage, team protection, recent-hit suppression and normal living-entity damage handling.
  • Make the living dragon resolvable by mob revenge goals, so an Enderman hurt by it can acquire the dragon as its target.
  • Draw F3+B hitboxes for synced area-effect clouds, including dragon breath: diameter follows the current radius, height is 0.5 blocks.
  • Add a real Java 26.3 oracle and Rust comparison for seven contact scenarios, plus an optional integrated-server regression check.

Updated onto upstream main at 6d91fa694 using a merge, preserving the published branch history. This does not replace the upstream breath-damage or hurt-flash fixes.

Vanilla references

EnderDragon.aiStep, EnderDragon.knockBack(ServerLevel, List), EnderDragon.hurt(ServerLevel, List), entity lookup used by revenge goals, and AreaEffectCloud.getDimensions(Pose) (radius × 2, height 0.5).

The oracle invokes the real private dragon contact methods from the pinned Java 26.3 server. No decompiled source, game jars, prepared resources or other mod source is included.

Verification

  • Seven Java/Rust contact scenarios pass on the updated base: flying, sitting, overlapping wings, team protection, head contact, recently hurt dragon and recently attacked victim. Health and revenge attribution match; velocities compare with absolute tolerance 1e-12.
  • cargo fmt --all -- --check: passed.
  • Python suite: 611 passed.
  • tools/pr_ready.py --quick --base origin/main: 2,062 client tests, 611 Python tests, formatting and documentation tests passed. The overall gate is not green: system Clippy is unavailable, and two generated-mod-API freshness tests report stale output. No generated mod-API files are changed by this PR.
  • Updated-base optimized build passed. The integrated-server regression passed in a fresh isolated world: the Enderman takes dragon contact damage and acquires the dragon as its revenge target.
  • Cloud dimensions checked against Java bytecode; visual rendering has not yet been manually verified in-game.

Scope

This is a contact/target-lookup fix, not a claim of complete dragon-fight parity. Phase selection, general pathfinding, breath damage to mobs and post-attack enchantment effects are outside this change. No issue comments or claims are posted by this agent.

The final follow-up commit only clarifies a Rust documentation comment to avoid a false Java-method citation in the port ledger.

Local self-check output

pr_ready (tools/pr_ready.py --quick on fedora, against origin/main at 6d91fa694, 2 min 41 s)

Check Result
Scope ✅ 15 files, +461 −4
Cargo.lock ✅ unchanged
Public tree ✅
Python tests ✅ 611 passed (54 s)
rustfmt ✅ (10 s)
clippy ❌ failed
tests: horizon-client, horizon-client-lib ✅ 2062 passed (1 min 21 s)
doc tests ✅ 0 passed (4 s)
content root tests ➖ content root untouched
mod API up to date ❌ failed (12 s)
tokens.css up to date ➖ theme untouched
launcher rustfmt ➖ launcher untouched
launcher clippy ➖ launcher untouched
launcher tests ➖ launcher untouched
Parity ➖ not run (--quick): CI's parity job picks the affected harnesses
Label player-facing: feature if players get something new, no label for a fix (release-now if urgent)

🤖 Generated with Codex


🔄 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/6977 **Author:** [@AltMugen](https://github.com/AltMugen) **Created:** 11/2/2026 **Status:** ✅ Merged **Merged:** 11/2/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `fix/dragon-living-contacts` --- ### 📝 Commits (5) - [`670350d`](https://github.com/horizon-rust/horizon/commit/670350d7e9ee5db4db4fa06e37b61dbad0107ca4) Fix dragon contacts with living mobs and revenge target lookup - [`100d494`](https://github.com/horizon-rust/horizon/commit/100d494541e26dd0b227d0e2ae70fd710f1af52b) Merge remote-tracking branch 'origin/main' into fix/dragon-living-contacts - [`4d2bde9`](https://github.com/horizon-rust/horizon/commit/4d2bde97e458d3c5e624fa87ec3c9c10f5100519) Show synced area effect cloud hitboxes in F3+B - [`f279047`](https://github.com/horizon-rust/horizon/commit/f2790475a36d43b3fd34331e770c5a0577bd024d) Clarify Rust damage-handler documentation for port ledger - [`715dd98`](https://github.com/horizon-rust/horizon/commit/715dd9811bed495efa144cd0db12194f999baa05) Merge main into #6977 ### 📊 Changes **15 files changed** (+461 additions, -4 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/examples/probe/mob_ai_probe.rs` (+1 -0) 📝 `crates/horizon-client/src/game/command_harness.rs` (+6 -0) 📝 `crates/horizon-client/src/game/creatures.rs` (+2 -0) 📝 `crates/horizon-client/src/game/debug_keys.rs` (+5 -0) 📝 `crates/horizon-client/src/game/dragon.rs` (+50 -0) 📝 `crates/horizon-client/src/game/remote_projectiles.rs` (+2 -2) 📝 `crates/horizon-client/src/mobs.rs` (+4 -1) ➕ `crates/horizon-client/src/mobs/dragon_contacts.rs` (+181 -0) 📝 `crates/horizon-client/src/mobs/living.rs` (+2 -0) 📝 `crates/horizon-client/src/mobs/world.rs` (+6 -0) 📝 `crates/horizon-client/src/mobs/zombie_villager.rs` (+1 -0) 📝 `mods/horizon/src/test/java/dev/horizonlab/parity/VanillaCommandExecOracle.java` (+10 -0) ➕ `mods/horizon/src/test/java/dev/horizonlab/parity/VanillaDragonContactsOracle.java` (+76 -0) 📝 `tools/port_map/game2-001.tsv` (+1 -1) ➕ `tools/test_dragon_contacts_parity.py` (+114 -0) </details> ### 📄 Description > 🤖 Opened by AltMugen's AI agent (Codex), not by AltMugen personally. ## Summary - Apply dragon wing/head/neck contacts to living mobs as well as players. Preserve sitting-wing push without damage, team protection, recent-hit suppression and normal living-entity damage handling. - Make the living dragon resolvable by mob revenge goals, so an Enderman hurt by it can acquire the dragon as its target. - Draw F3+B hitboxes for synced area-effect clouds, including dragon breath: diameter follows the current radius, height is 0.5 blocks. - Add a real Java 26.3 oracle and Rust comparison for seven contact scenarios, plus an optional integrated-server regression check. Updated onto upstream `main` at `6d91fa694` using a merge, preserving the published branch history. This does not replace the upstream breath-damage or hurt-flash fixes. ## Vanilla references `EnderDragon.aiStep`, `EnderDragon.knockBack(ServerLevel, List)`, `EnderDragon.hurt(ServerLevel, List)`, entity lookup used by revenge goals, and `AreaEffectCloud.getDimensions(Pose)` (radius × 2, height 0.5). The oracle invokes the real private dragon contact methods from the pinned Java 26.3 server. No decompiled source, game jars, prepared resources or other mod source is included. ## Verification - Seven Java/Rust contact scenarios pass on the updated base: flying, sitting, overlapping wings, team protection, head contact, recently hurt dragon and recently attacked victim. Health and revenge attribution match; velocities compare with absolute tolerance 1e-12. - `cargo fmt --all -- --check`: passed. - Python suite: 611 passed. - `tools/pr_ready.py --quick --base origin/main`: 2,062 client tests, 611 Python tests, formatting and documentation tests passed. The overall gate is not green: system Clippy is unavailable, and two generated-mod-API freshness tests report stale output. No generated mod-API files are changed by this PR. - Updated-base optimized build passed. The integrated-server regression passed in a fresh isolated world: the Enderman takes dragon contact damage and acquires the dragon as its revenge target. - Cloud dimensions checked against Java bytecode; visual rendering has not yet been manually verified in-game. ## Scope This is a contact/target-lookup fix, not a claim of complete dragon-fight parity. Phase selection, general pathfinding, breath damage to mobs and post-attack enchantment effects are outside this change. No issue comments or claims are posted by this agent. The final follow-up commit only clarifies a Rust documentation comment to avoid a false Java-method citation in the port ledger. ## Local self-check output **pr_ready** (`tools/pr_ready.py --quick` on fedora, against origin/main at 6d91fa694, 2 min 41 s) | Check | Result | | --- | --- | | Scope | ✅ 15 files, +461 −4 | | Cargo.lock | ✅ unchanged | | Public tree | ✅ | | Python tests | ✅ 611 passed (54 s) | | rustfmt | ✅ (10 s) | | clippy | ❌ failed | | tests: horizon-client, horizon-client-lib | ✅ 2062 passed (1 min 21 s) | | doc tests | ✅ 0 passed (4 s) | | content root tests | ➖ content root untouched | | mod API up to date | ❌ failed (12 s) | | tokens.css up to date | ➖ theme untouched | | launcher rustfmt | ➖ launcher untouched | | launcher clippy | ➖ launcher untouched | | launcher tests | ➖ launcher untouched | | Parity | ➖ not run (--quick): CI's parity job picks the affected harnesses | | Label | player-facing: `feature` if players get something new, no label for a fix (`release-now` if urgent) | 🤖 Generated with [Codex](https://openai.com/codex/) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 06:36:23 +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#7248
No description provided.