mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-26 09:35:28 +00:00
3042c000c6
* resets state updater to apply light settings (#3141) resets state updater to apply light settings With this PR we achieve the same effect with fewer lines of code. * fixes LightSource logic errors We currently update `LightSource::setActorFade` in `TransparencyUpdater`. There are several logic errors inherent in this approach: 1. We fail to update `LightSource::setActorFade` for off screen actors because their `TransparencyUpdater` cull callback is not invoked. 2. We fail to update `LightSource::setActorFade` in the instant that a `TransparencyUpdater` is removed. 3. We fail to update `setActorFade` when an `mExtraLightSource` is created after calling `Animation::setAlpha`. With this PR we avoid such issues by updating `LightSource::setActorFade` in `Animation::setAlpha` and `Animation::addExtraLightSource` instead.