mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
Remove stock planets immediately since we use SearchUtility anyway
This commit is contained in:
parent
09ddb2f780
commit
be9df72756
@ -32,6 +32,8 @@ namespace NewHorizons.Handlers
|
|||||||
|
|
||||||
public static void Init(List<NewHorizonsBody> bodies)
|
public static void Init(List<NewHorizonsBody> bodies)
|
||||||
{
|
{
|
||||||
|
if (Main.SystemDict[Main.Instance.CurrentStarSystem].Config.destroyStockPlanets) PlanetDestructionHandler.RemoveStockPlanets();
|
||||||
|
|
||||||
Main.FurthestOrbit = 30000;
|
Main.FurthestOrbit = 30000;
|
||||||
|
|
||||||
_existingBodyDict = new();
|
_existingBodyDict = new();
|
||||||
@ -135,8 +137,6 @@ namespace NewHorizons.Handlers
|
|||||||
SingularityBuilder.PairAllSingularities();
|
SingularityBuilder.PairAllSingularities();
|
||||||
|
|
||||||
// Events.FireOnNextUpdate(PlanetDestroyer.RemoveAllProxies);
|
// Events.FireOnNextUpdate(PlanetDestroyer.RemoveAllProxies);
|
||||||
|
|
||||||
if (Main.SystemDict[Main.Instance.CurrentStarSystem].Config.destroyStockPlanets) PlanetDestructionHandler.RemoveStockPlanets();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static bool LoadBody(NewHorizonsBody body, bool defaultPrimaryToSun = false)
|
public static bool LoadBody(NewHorizonsBody body, bool defaultPrimaryToSun = false)
|
||||||
|
|||||||
@ -54,19 +54,12 @@ namespace NewHorizons.Handlers
|
|||||||
|
|
||||||
public static void RemoveSolarSystem()
|
public static void RemoveSolarSystem()
|
||||||
{
|
{
|
||||||
// Stop the sun from killing the player
|
|
||||||
var sunVolumes = SearchUtilities.Find("Sun_Body/Sector_SUN/Volumes_SUN");
|
|
||||||
sunVolumes.SetActive(false);
|
|
||||||
|
|
||||||
foreach (var name in _solarSystemBodies)
|
foreach (var name in _solarSystemBodies)
|
||||||
{
|
{
|
||||||
var ao = AstroObjectLocator.GetAstroObject(name);
|
var ao = AstroObjectLocator.GetAstroObject(name);
|
||||||
if (ao != null) Delay.FireInNUpdates(() => RemoveBody(ao, false), 2);
|
if (ao != null) RemoveBody(ao, false);
|
||||||
else NHLogger.LogError($"Couldn't find [{name}]");
|
else NHLogger.LogError($"Couldn't find [{name}]");
|
||||||
}
|
}
|
||||||
|
|
||||||
// Bring the sun back because why not
|
|
||||||
Delay.FireInNUpdates(() => { if (Locator.GetAstroObject(AstroObject.Name.Sun).gameObject.activeInHierarchy) { sunVolumes.SetActive(true); } }, 3);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void RemoveEyeOfTheUniverse()
|
public static void RemoveEyeOfTheUniverse()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user