mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-26 18:35:20 +00:00
Moon fading fix (Bug #2713)
This commit is contained in:
parent
7a5f220ac5
commit
38d90f47a6
@ -495,8 +495,6 @@ void WeatherManager::update(float duration, bool paused)
|
||||
|
||||
mRendering->getSkyManager()->setMasserDirection(masser);
|
||||
mRendering->getSkyManager()->setSecundaDirection(secunda);
|
||||
mRendering->getSkyManager()->masserEnable();
|
||||
mRendering->getSkyManager()->secundaEnable();
|
||||
|
||||
float angle = (1-moonHeight) * 90.f * facing;
|
||||
float masserHourFade = calculateHourFade("Masser");
|
||||
@ -507,8 +505,22 @@ void WeatherManager::update(float duration, bool paused)
|
||||
masserAngleFade *= masserHourFade;
|
||||
secundaAngleFade *= secundaHourFade;
|
||||
|
||||
mRendering->getSkyManager()->setMasserFade(masserAngleFade);
|
||||
mRendering->getSkyManager()->setSecundaFade(secundaAngleFade);
|
||||
if (masserAngleFade > 0)
|
||||
{
|
||||
mRendering->getSkyManager()->setMasserFade(masserAngleFade);
|
||||
mRendering->getSkyManager()->masserEnable();
|
||||
}
|
||||
else
|
||||
mRendering->getSkyManager()->masserDisable();
|
||||
|
||||
if (secundaAngleFade > 0)
|
||||
{
|
||||
mRendering->getSkyManager()->setSecundaFade(secundaAngleFade);
|
||||
mRendering->getSkyManager()->secundaEnable();
|
||||
}
|
||||
else
|
||||
mRendering->getSkyManager()->secundaDisable();
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user