[PR #2335] [MERGED] Make Frost Walker freeze water and protect from magma #4216

Closed
opened 2026-11-03 04:15:33 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/2335
Author: @kacpherek
Created: 10/26/2026
Status: ✅ Merged
Merged: 10/27/2026
Merged by: @ludovic111

Base: main ← Head: fix/frost-walker


📝 Commits (2)

  • e4cd56e Make Frost Walker freeze water and protect from magma
  • 14353e6 Merge remote-tracking branch 'origin/main' into HEAD

📊 Changes

5 files changed (+226 additions, -2 deletions)

View changed files

📝 crates/horizon-client/src/game.rs (+7 -0)
📝 crates/horizon-client/src/game/enchant_effects.rs (+205 -2)
📝 crates/horizon-client/src/game/lan_actions.rs (+5 -0)
📝 crates/horizon-client/src/motion.rs (+3 -0)
📝 crates/horizon-client/src/motion/environment.rs (+6 -0)

📄 Description

What and why

Frost Walker did nothing: walking over water did not freeze it, and magma blocks still burned. Horizon had no minecraft:location_changed enchantment effects and ignored the enchantment's damage_immunity.

The server now runs the worn armor's location_changed replace_disk effects when the player's block position changes or the player lands. For Frost Walker this turns water source blocks around the feet (radius 3 plus the level above first, clamped to 16) into frosted_ice age 0. The existing frosted ice code schedules its ticks and melts it. The effect's requirements (on the ground, not riding) and block predicate (air above, water source, unobstructed) are read from the enchantment data. It runs on the server for both the in-frame player and LAN/in-process guests; a remote client does not place anything.

The enchantment's damage_immunity for #burn_from_stepping now stops hot floor (magma block) and campfire damage for the wearer.

Mobs wearing boots are not covered.

Vanilla reference

  • LivingEntity.baseTick and checkFallDamage -> onChangedBlock -> EnchantmentHelper.runLocationChangedEffects
  • ReplaceDisk.apply
  • MatchingBlockTagPredicate, MatchingBlocksPredicate, MatchingFluidsPredicate, UnobstructedPredicate
  • data/minecraft/enchantment/frost_walker.json, tags/damage_type/burn_from_stepping.json

Self-check

cargo check -p horizon-client passes.


🔄 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/2335 **Author:** [@kacpherek](https://github.com/kacpherek) **Created:** 10/26/2026 **Status:** ✅ Merged **Merged:** 10/27/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `fix/frost-walker` --- ### 📝 Commits (2) - [`e4cd56e`](https://github.com/horizon-rust/horizon/commit/e4cd56ed7b44cbe5af3835a4f3ba9730c96ad051) Make Frost Walker freeze water and protect from magma - [`14353e6`](https://github.com/horizon-rust/horizon/commit/14353e67d4cde234c59fd7835a5f428107a445a0) Merge remote-tracking branch 'origin/main' into HEAD ### 📊 Changes **5 files changed** (+226 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/src/game.rs` (+7 -0) 📝 `crates/horizon-client/src/game/enchant_effects.rs` (+205 -2) 📝 `crates/horizon-client/src/game/lan_actions.rs` (+5 -0) 📝 `crates/horizon-client/src/motion.rs` (+3 -0) 📝 `crates/horizon-client/src/motion/environment.rs` (+6 -0) </details> ### 📄 Description ## What and why Frost Walker did nothing: walking over water did not freeze it, and magma blocks still burned. Horizon had no `minecraft:location_changed` enchantment effects and ignored the enchantment's `damage_immunity`. The server now runs the worn armor's `location_changed` `replace_disk` effects when the player's block position changes or the player lands. For Frost Walker this turns water source blocks around the feet (radius 3 plus the level above first, clamped to 16) into `frosted_ice` age 0. The existing frosted ice code schedules its ticks and melts it. The effect's requirements (on the ground, not riding) and block predicate (air above, water source, unobstructed) are read from the enchantment data. It runs on the server for both the in-frame player and LAN/in-process guests; a remote client does not place anything. The enchantment's `damage_immunity` for `#burn_from_stepping` now stops hot floor (magma block) and campfire damage for the wearer. Mobs wearing boots are not covered. ## Vanilla reference - `LivingEntity.baseTick` and `checkFallDamage` -> `onChangedBlock` -> `EnchantmentHelper.runLocationChangedEffects` - `ReplaceDisk.apply` - `MatchingBlockTagPredicate`, `MatchingBlocksPredicate`, `MatchingFluidsPredicate`, `UnobstructedPredicate` - `data/minecraft/enchantment/frost_walker.json`, `tags/damage_type/burn_from_stepping.json` ## Self-check `cargo check -p horizon-client` passes. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 04:15:33 +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#4216
No description provided.