[PR #3647] [MERGED] elder guardian: a player already cursed isn't cursed again every minute #5122

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

📋 Pull Request Information

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

Base: main ← Head: elder-curse-skips-cursed


📝 Commits (1)

  • 4e5b26f elder guardian: a player already cursed isn't cursed again every minute

📊 Changes

1 file changed (+4 additions, -2 deletions)

View changed files

📝 crates/horizon-client/src/game/creatures.rs (+4 -2)

📄 Description

What and why

A player near an elder guardian was cursed again at every 1200-tick pulse, with the curse sound and the apparition each minute, even with five minutes of Mining Fatigue III left. The check for a curse already on looked up minecraft:mining_fatigue, but the player's effects are kept by their bare name, so it never matched. It now looks up mining_fatigue and, as vanilla, keeps a curse as strong that doesn't end within the next minute (an infinite one included).

Vanilla reference

ElderGuardian.customServerAiStep calls MobEffectUtil.addEffectToPlayersAround(level, this, pos, 50.0, MINING_FATIGUE 6000 II, 1200), which only picks a player without the effect, with a weaker one, or with one that endsWithin(1199); only those get GUARDIAN_ELDER_EFFECT.

Self-check

pr_ready (tools/pr_ready.py --quick on PC-Lost, against origin/main at 64990cd32, 2 min 14 s)

Check Result
Scope ✅ 1 files, +4 −2
Cargo.lock ✅ unchanged
Public tree ✅
Python tests ❌ 408 run, FAILED (failures=1, skipped=12) (1 min 4 s)
rustfmt ✅ (10 s)
clippy ✅ (14 s)
tests: horizon-client ✅ 797 passed (34 s)
doc tests ✅ 0 passed (9 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 (--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)

The one failure under Python tests is test_port_publish.PublishTests.test_body_has_names_and_signatures_only, a ~/ against ~\ path check that fails on Windows on main too. Parity is left to CI.


🔄 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/3647 **Author:** [@iLostName](https://github.com/iLostName) **Created:** 10/29/2026 **Status:** ✅ Merged **Merged:** 10/29/2026 **Merged by:** [@levzzz5154](https://github.com/levzzz5154) **Base:** `main` ← **Head:** `elder-curse-skips-cursed` --- ### 📝 Commits (1) - [`4e5b26f`](https://github.com/horizon-rust/horizon/commit/4e5b26f9fb2209689b845445a658b0285cba421d) elder guardian: a player already cursed isn't cursed again every minute ### 📊 Changes **1 file changed** (+4 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/src/game/creatures.rs` (+4 -2) </details> ### 📄 Description ## What and why A player near an elder guardian was cursed again at every 1200-tick pulse, with the curse sound and the apparition each minute, even with five minutes of Mining Fatigue III left. The check for a curse already on looked up `minecraft:mining_fatigue`, but the player's effects are kept by their bare name, so it never matched. It now looks up `mining_fatigue` and, as vanilla, keeps a curse as strong that doesn't end within the next minute (an infinite one included). ## Vanilla reference `ElderGuardian.customServerAiStep` calls `MobEffectUtil.addEffectToPlayersAround(level, this, pos, 50.0, MINING_FATIGUE 6000 II, 1200)`, which only picks a player without the effect, with a weaker one, or with one that `endsWithin(1199)`; only those get `GUARDIAN_ELDER_EFFECT`. ## Self-check **pr_ready** (`tools/pr_ready.py --quick` on PC-Lost, against origin/main at 64990cd32, 2 min 14 s) | Check | Result | | --- | --- | | Scope | ✅ 1 files, +4 −2 | | Cargo.lock | ✅ unchanged | | Public tree | ✅ | | Python tests | ❌ 408 run, FAILED (failures=1, skipped=12) (1 min 4 s) | | rustfmt | ✅ (10 s) | | clippy | ✅ (14 s) | | tests: horizon-client | ✅ 797 passed (34 s) | | doc tests | ✅ 0 passed (9 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 (--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) | The one failure under Python tests is `test_port_publish.PublishTests.test_body_has_names_and_signatures_only`, a `~/` against `~\` path check that fails on Windows on main too. Parity is left to CI. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 05:10: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#5122
No description provided.