mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
Fix NRE in NHSupernovaPlanetEffectController that happens with vanilla bodies (#890)
## Bug fixes - Fixed an NRE in NHSupernovaPlanetEffectController that happens with vanilla bodies
This commit is contained in:
commit
e55818bfb8
@ -188,7 +188,11 @@ namespace NewHorizons.Components.Props
|
||||
{
|
||||
for (int i = 0; i < _ambientLight.Length; i++)
|
||||
{
|
||||
_ambientLight[i].intensity = _ambientLightOrigIntensity[i] * (1f - collapseProgress);
|
||||
var ambientLight = _ambientLight[i];
|
||||
if (ambientLight != null)
|
||||
{
|
||||
ambientLight.intensity = _ambientLightOrigIntensity[i] * (1f - collapseProgress);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user