[PR #4265] [MERGED] A hit stands a sitting tame parrot up #5529

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

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/4265
Author: @DenisHumen
Created: 10/30/2026
Status: ✅ Merged
Merged: 10/31/2026
Merged by: @rdbtCVS

Base: main ← Head: fix/parrot-stands-when-hurt


📝 Commits (2)

  • e17aabe A hit stands a sitting tame parrot up
  • 93892c4 Merge main into fix/parrot-stands-when-hurt

📊 Changes

2 files changed (+54 additions, -6 deletions)

View changed files

📝 crates/horizon-client/src/mobs/ai.rs (+7 -1)
📝 crates/horizon-client/src/mobs/tame.rs (+47 -5)

📄 Description

🤖 Opened by DenisHumen's AI agent (Claude Code, Opus 5.5), not by DenisHumen personally.

What

A hit now stands a sitting tame parrot up. A wolf hit inside its hurt frames (a weaker second hit that deals nothing) now stands up too.

  • mobs/ai.rs accepts_damage: wolves and parrots stop sitting there. accepts_damage runs after the invulnerability and fire-immunity checks and before the hurt frames, the same place as vanilla's override. It already handles the bat waking and the panda standing up on a hit.
  • mobs/tame.rs: after_hurt (wolf only, run after the damage landed) becomes stand_when_hurt, and the wolf arm in ai::after_hurt is removed.

Why (vanilla 26.3)

javap -c on the 26.3 client jar:

  • Parrot.hurtServer: if (isInvulnerableTo(level, source)) return false; setOrderedToSit(false); return super.hurtServer(...)
  • Wolf.hurtServer: the same.
  • Cat has no hurtServer override, so a hit leaves a sitting cat sitting. A test covers that.

Horizon only did this for wolves, and only once damage got through. So a sitting parrot stayed sitting when hit.

This is the Parrot.hurtServer (missing) row of #3512. I didn't use "Fixes", because that issue is a tracker with many rows. Once this is merged, the row can be ticked.

Checked

  • New mobs::tame::tests: a_hit_stands_a_sitting_wolf_or_parrot_up and a_hit_leaves_a_sitting_cat_sitting. With the ai.rs change reverted, the wolf/parrot test fails at the blocked wolf hit and the parrot hit. With the change, both pass.
  • cargo clippy -p horizon-client --all-targets -- -D warnings -A clippy::manual_range_contains -A clippy::nonminimal_bool -A clippy::overly_complex_bool_expr is clean.
  • Not checked in game.

pr_ready on Windows has two red rows, and neither comes from this change:

  • clippy: a clippy 1.96 manual_range_contains lint in horizon-world.
  • title::tests::each_world_preset_writes_its_own_generator: fails on Windows with NotADirectory (os error 267).

The parity harnesses don't run on Windows (fcntl).

Part of #3512.

pr_ready (tools/pr_ready.py --base upstream/main on DenisPC, against upstream/main at bb6406719, 2 min 33 s)

Check Result
Scope ✅ 2 files, +60 −5
Cargo.lock ✅ unchanged
Public tree ✅
Python tests ✅ 480 passed (1 min 9 s)
rustfmt ✅ (8 s)
clippy ❌ failed (16 s) (clippy 1.96 lint in horizon-world, see above)
tests: horizon-client ❌ 728 passed, 1 failed (55 s) (title world_preset test, Windows only, see above)
doc tests ✅ 0 passed (2 s)
content root tests ➖ content root untouched
tokens.css up to date ➖ theme untouched
launcher rustfmt ➖ launcher untouched
launcher clippy ➖ launcher untouched
launcher tests ➖ launcher untouched
Parity ➖ not run (no vanilla data here): CI's parity job picks the affected harnesses
Label player-facing: no label for a fix

🤖 Generated with Claude Code


🔄 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/4265 **Author:** [@DenisHumen](https://github.com/DenisHumen) **Created:** 10/30/2026 **Status:** ✅ Merged **Merged:** 10/31/2026 **Merged by:** [@rdbtCVS](https://github.com/rdbtCVS) **Base:** `main` ← **Head:** `fix/parrot-stands-when-hurt` --- ### 📝 Commits (2) - [`e17aabe`](https://github.com/horizon-rust/horizon/commit/e17aabe3226ce3c4e54e53bcda3c3072be216d05) A hit stands a sitting tame parrot up - [`93892c4`](https://github.com/horizon-rust/horizon/commit/93892c404955035bd804e61cf8945be84ff9067a) Merge main into fix/parrot-stands-when-hurt ### 📊 Changes **2 files changed** (+54 additions, -6 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/src/mobs/ai.rs` (+7 -1) 📝 `crates/horizon-client/src/mobs/tame.rs` (+47 -5) </details> ### 📄 Description > 🤖 Opened by DenisHumen's AI agent (Claude Code, Opus 5.5), not by DenisHumen personally. ## What A hit now stands a sitting tame parrot up. A wolf hit inside its hurt frames (a weaker second hit that deals nothing) now stands up too. - `mobs/ai.rs` `accepts_damage`: wolves and parrots stop sitting there. `accepts_damage` runs after the invulnerability and fire-immunity checks and before the hurt frames, the same place as vanilla's override. It already handles the bat waking and the panda standing up on a hit. - `mobs/tame.rs`: `after_hurt` (wolf only, run after the damage landed) becomes `stand_when_hurt`, and the wolf arm in `ai::after_hurt` is removed. ## Why (vanilla 26.3) `javap -c` on the 26.3 client jar: - `Parrot.hurtServer`: `if (isInvulnerableTo(level, source)) return false; setOrderedToSit(false); return super.hurtServer(...)` - `Wolf.hurtServer`: the same. - `Cat` has no `hurtServer` override, so a hit leaves a sitting cat sitting. A test covers that. Horizon only did this for wolves, and only once damage got through. So a sitting parrot stayed sitting when hit. This is the `Parrot.hurtServer (missing)` row of #3512. I didn't use "Fixes", because that issue is a tracker with many rows. Once this is merged, the row can be ticked. ## Checked - New `mobs::tame::tests`: `a_hit_stands_a_sitting_wolf_or_parrot_up` and `a_hit_leaves_a_sitting_cat_sitting`. With the `ai.rs` change reverted, the wolf/parrot test fails at the blocked wolf hit and the parrot hit. With the change, both pass. - `cargo clippy -p horizon-client --all-targets -- -D warnings -A clippy::manual_range_contains -A clippy::nonminimal_bool -A clippy::overly_complex_bool_expr` is clean. - Not checked in game. pr_ready on Windows has two red rows, and neither comes from this change: - clippy: a clippy 1.96 `manual_range_contains` lint in `horizon-world`. - `title::tests::each_world_preset_writes_its_own_generator`: fails on Windows with `NotADirectory` (os error 267). The parity harnesses don't run on Windows (`fcntl`). Part of #3512. **pr_ready** (`tools/pr_ready.py --base upstream/main` on DenisPC, against upstream/main at bb6406719, 2 min 33 s) | Check | Result | | --- | --- | | Scope | ✅ 2 files, +60 −5 | | Cargo.lock | ✅ unchanged | | Public tree | ✅ | | Python tests | ✅ 480 passed (1 min 9 s) | | rustfmt | ✅ (8 s) | | clippy | ❌ failed (16 s) (clippy 1.96 lint in horizon-world, see above) | | tests: horizon-client | ❌ 728 passed, 1 failed (55 s) (title world_preset test, Windows only, see above) | | doc tests | ✅ 0 passed (2 s) | | content root tests | ➖ content root untouched | | tokens.css up to date | ➖ theme untouched | | launcher rustfmt | ➖ launcher untouched | | launcher clippy | ➖ launcher untouched | | launcher tests | ➖ launcher untouched | | Parity | ➖ not run (no vanilla data here): CI's parity job picks the affected harnesses | | Label | player-facing: no label for a fix | 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 05:13:12 +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#5529
No description provided.