mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
Replaced invulernableToSun to hasFluidDetector, document anglerfish behaviour (#830)
This commit is contained in:
parent
e793ce92cb
commit
c9fa785ac6
@ -19,7 +19,7 @@ namespace NewHorizons.Builder.General
|
||||
|
||||
astroObject.isVanilla = isVanilla;
|
||||
astroObject.HideDisplayName = !config.MapMarker.enabled;
|
||||
astroObject.invulnerableToSun = config.Base.invulnerableToSun;
|
||||
astroObject.invulnerableToSun = !config.Base.hasFluidDetector;
|
||||
|
||||
if (config.Orbit != null) astroObject.SetOrbitalParametersFromConfig(config.Orbit);
|
||||
|
||||
|
||||
@ -90,7 +90,7 @@ namespace NewHorizons.Builder.General
|
||||
OWRB.RegisterAttachedForceDetector(forceDetector);
|
||||
|
||||
// For falling into sun
|
||||
if (!config.Base.invulnerableToSun && config.Star == null && config.FocalPoint == null)
|
||||
if (config.Base.hasFluidDetector && config.Star == null && config.FocalPoint == null)
|
||||
{
|
||||
detectorGO.layer = Layer.AdvancedDetector;
|
||||
|
||||
|
||||
7
NewHorizons/External/Configs/PlanetConfig.cs
vendored
7
NewHorizons/External/Configs/PlanetConfig.cs
vendored
@ -281,7 +281,7 @@ namespace NewHorizons.External.Configs
|
||||
}
|
||||
|
||||
// Stars and focal points shouldnt be destroyed by stars
|
||||
if (Star != null || FocalPoint != null) Base.invulnerableToSun = true;
|
||||
if (Star != null || FocalPoint != null) Base.hasFluidDetector = false;
|
||||
}
|
||||
|
||||
public void Migrate()
|
||||
@ -664,6 +664,11 @@ namespace NewHorizons.External.Configs
|
||||
if (destructionVolume.onlyAffectsPlayerAndShip) destructionVolume.onlyAffectsPlayerRelatedBodies = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (Base.invulnerableToSun)
|
||||
{
|
||||
Base.hasFluidDetector = false;
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
|
||||
9
NewHorizons/External/Modules/BaseModule.cs
vendored
9
NewHorizons/External/Modules/BaseModule.cs
vendored
@ -37,9 +37,11 @@ namespace NewHorizons.External.Modules
|
||||
public float groundSize;
|
||||
|
||||
/// <summary>
|
||||
/// Can this planet survive entering a star?
|
||||
/// Is this planet able to detect fluid volumes? Disabling this means that entering a star or lava volume will not destroy this planet
|
||||
/// May have adverse effects if anglerfish are added to this planet, disable this if you want those to work (they have fluid volumes in their mouths)
|
||||
/// </summary>
|
||||
public bool invulnerableToSun;
|
||||
[DefaultValue(true)]
|
||||
public bool hasFluidDetector = true;
|
||||
|
||||
/// <summary>
|
||||
/// Do we show the minimap when walking around this planet?
|
||||
@ -84,6 +86,9 @@ namespace NewHorizons.External.Modules
|
||||
|
||||
#region Obsolete
|
||||
|
||||
[Obsolete("invulnerableToSun is deprecated, please use hasFluidDetector instead")]
|
||||
public bool invulnerableToSun;
|
||||
|
||||
[Obsolete("IsSatellite is deprecated, please use ShowMinimap instead")]
|
||||
public bool isSatellite;
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user