From 4b5ce67ecde3da7465e165cb08b7253504164729 Mon Sep 17 00:00:00 2001 From: Victor Giers Date: Wed, 22 Apr 2026 12:36:07 +0200 Subject: [PATCH] auto-git: [change] src/runtime-three/runtime-project-time.ts --- src/runtime-three/runtime-project-time.ts | 35 ++++++++++++++--------- 1 file changed, 21 insertions(+), 14 deletions(-) diff --git a/src/runtime-three/runtime-project-time.ts b/src/runtime-three/runtime-project-time.ts index 979cf1af..6398e87a 100644 --- a/src/runtime-three/runtime-project-time.ts +++ b/src/runtime-three/runtime-project-time.ts @@ -731,20 +731,27 @@ function resolveTimeDrivenBackground( const nightBackground = timeOfDay.night.background; const twilightNightOpacity = weights.night + weights.dawn * 0.5 + weights.dusk * 0.5; - const daylikeImageBackground = resolvePreferredDaylikeImageBackground([ - { - background: dayBackground, - weight: weights.day - }, - { - background: dawnBackground, - weight: weights.dawn - }, - { - background: duskBackground, - weight: weights.dusk - } - ]); + const daylikeImageBackground = + weights.dawn > 1e-6 && hasConfiguredImageBackground(dawnBackground) + ? cloneWorldBackgroundSettings(dawnBackground) + : weights.dusk > 1e-6 && hasConfiguredImageBackground(duskBackground) + ? cloneWorldBackgroundSettings(duskBackground) + : hasConfiguredImageBackground(dayBackground) + ? cloneWorldBackgroundSettings(dayBackground) + : resolvePreferredDaylikeImageBackground([ + { + background: dayBackground, + weight: weights.day + }, + { + background: dawnBackground, + weight: weights.dawn + }, + { + background: duskBackground, + weight: weights.dusk + } + ]); if (daylikeImageBackground !== null) { const nightOverlay =