Merge pull request #2385 from kacpherek/fix/lightning-sky-flash

🤖 Agent: Proven in union R1 (branch union/cg19-r1, main + 83 of kacpherek's PRs): the 98 harnesses it can affect, clippy -D warnings, tests, lan_e2e in-frame and on the server thread.
This commit is contained in:
Ludovic Marie
2026-10-27 14:48:05 +01:00
committed by GitHub
+5 -2
View File
@@ -11258,8 +11258,11 @@ impl Game<'_> {
horizon_client::environment::apply_weather(&mut sky, rain, thunder);
self.end_flash_sky(&mut sky, alpha);
if self.flash > 0 && !self.settings.file.bool("hideLightningFlashes") {
// Lightning flash brightens the sky (LevelRenderer skyFlashTime).
sky.sky_color = [0.9, 0.9, 1.0];
// ClientLevel's flash layer while skyFlashTime > 0: the sky colour
// moves 22% of the way to (0.8, 0.8, 1.0).
let flash = [0.8, 0.8, 1.0];
sky.sky_color =
std::array::from_fn(|i| sky.sky_color[i] + (flash[i] - sky.sky_color[i]) * 0.22);
sky.sky_light_factor = 1.0;
}
// FishingHookRenderer's line, then DebugRenderer: chunk borders and