mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
Don't even try to supernova if it is null
This commit is contained in:
parent
a1aa65dda8
commit
f2dd6b04d2
@ -370,6 +370,7 @@ namespace NewHorizons.Components.SizeControllers
|
||||
|
||||
public void StartSupernova()
|
||||
{
|
||||
if (supernova == null) return;
|
||||
if (_isSupernova) return;
|
||||
|
||||
Logger.LogVerbose($"{gameObject.transform.root.name} started supernova");
|
||||
@ -393,7 +394,7 @@ namespace NewHorizons.Components.SizeControllers
|
||||
Logger.LogVerbose($"{gameObject.transform.root.name} stopped supernova");
|
||||
|
||||
SupernovaStop.Invoke();
|
||||
supernova.Deactivate();
|
||||
if (supernova != null) supernova.Deactivate();
|
||||
_isSupernova = false;
|
||||
if (atmosphere != null) atmosphere.SetActive(true);
|
||||
if (destructionVolume != null)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user