[PR #2383] [MERGED] Follow vanilla's lava fog for Fire Resistance and spectators, and brighten fog with Night Vision #4263

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

📋 Pull Request Information

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

Base: main ← Head: fix/fog-lava-and-night-vision


📝 Commits (3)

  • 36ebd0c Follow vanilla's lava fog for Fire Resistance and spectators, and brighten the fog colour with Night Vision
  • 4d0962e Merge main into fix/fog-lava-and-night-vision
  • 504aa1d Merge main into this branch

📊 Changes

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

View changed files

📝 crates/horizon-client-render/src/fog.rs (+25 -5)
📝 crates/horizon-client/src/game/render_tick.rs (+19 -0)

📄 Description

What and why

Two fog gaps:

  • Inside lava the fog was always the short 0.25 to 1.0 range. With Fire Resistance vanilla pushes it out to 0 to 5 blocks, and a spectator sees 8 blocks behind them out to half the render distance.
  • Night Vision did not lift the fog colour. Vanilla scales it toward its brightest channel by the Night Vision strength (not while Darkness is on), so fog stays visible instead of dull and dark.

FogInputs now carries spectator, fire_resistance and night_vision, filled in from the player's state in frame_fog.

Vanilla reference

  • LavaFogEnvironment.setupFog: spectator (-8, renderDistance * 0.5), Fire Resistance (0, 5), otherwise (0.25, 1.0); sky and cloud end follow the environmental end.
  • FogRenderer.computeFogColor: brightenFactor is the water vision in water, else GameRenderer.nightVisionScale with Night Vision and no Darkness, else 0.

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/2383 **Author:** [@kacpherek](https://github.com/kacpherek) **Created:** 10/26/2026 **Status:** ✅ Merged **Merged:** 10/29/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `fix/fog-lava-and-night-vision` --- ### 📝 Commits (3) - [`36ebd0c`](https://github.com/horizon-rust/horizon/commit/36ebd0c54508bec0550c66fc84618f31cc6835e6) Follow vanilla's lava fog for Fire Resistance and spectators, and brighten the fog colour with Night Vision - [`4d0962e`](https://github.com/horizon-rust/horizon/commit/4d0962e611dbcfbb005b069d8ec1c33867ac6899) Merge main into fix/fog-lava-and-night-vision - [`504aa1d`](https://github.com/horizon-rust/horizon/commit/504aa1dca65334f2a72f0aa42802dfa8a8c4d586) Merge main into this branch ### 📊 Changes **2 files changed** (+44 additions, -5 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client-render/src/fog.rs` (+25 -5) 📝 `crates/horizon-client/src/game/render_tick.rs` (+19 -0) </details> ### 📄 Description ## What and why Two fog gaps: - Inside lava the fog was always the short 0.25 to 1.0 range. With Fire Resistance vanilla pushes it out to 0 to 5 blocks, and a spectator sees 8 blocks behind them out to half the render distance. - Night Vision did not lift the fog colour. Vanilla scales it toward its brightest channel by the Night Vision strength (not while Darkness is on), so fog stays visible instead of dull and dark. `FogInputs` now carries `spectator`, `fire_resistance` and `night_vision`, filled in from the player's state in `frame_fog`. ## Vanilla reference - `LavaFogEnvironment.setupFog`: spectator (-8, renderDistance * 0.5), Fire Resistance (0, 5), otherwise (0.25, 1.0); sky and cloud end follow the environmental end. - `FogRenderer.computeFogColor`: `brightenFactor` is the water vision in water, else `GameRenderer.nightVisionScale` with Night Vision and no Darkness, else 0. ## 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:53 +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#4263
No description provided.