mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
Reference Frame Enabled
This commit is contained in:
parent
cd7086f669
commit
de05bfa2e0
@ -43,7 +43,8 @@ namespace NewHorizons.Builder.General
|
|||||||
|
|
||||||
owrb.SetAttachedReferenceFrameVolume(RFV);
|
owrb.SetAttachedReferenceFrameVolume(RFV);
|
||||||
|
|
||||||
rfGO.SetActive(!module.hideInMap);
|
if (!module.enabled) GameObject.Destroy(rfGO);
|
||||||
|
else rfGO.SetActive(!module.hideInMap);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -59,6 +59,7 @@ namespace NewHorizons.Builder.Orbital
|
|||||||
fakeMassConfig.name = config.name + "_FakeBarycenterMass";
|
fakeMassConfig.name = config.name + "_FakeBarycenterMass";
|
||||||
fakeMassConfig.Base.soiOverride = 0;
|
fakeMassConfig.Base.soiOverride = 0;
|
||||||
fakeMassConfig.Base.hasMapMarker = false;
|
fakeMassConfig.Base.hasMapMarker = false;
|
||||||
|
fakeMassConfig.ReferenceFrame.enabled = false;
|
||||||
fakeMassConfig.ReferenceFrame.hideInMap = true;
|
fakeMassConfig.ReferenceFrame.hideInMap = true;
|
||||||
|
|
||||||
fakeMassConfig.Orbit = new OrbitModule();
|
fakeMassConfig.Orbit = new OrbitModule();
|
||||||
|
|||||||
@ -119,7 +119,7 @@ namespace NewHorizons.Components
|
|||||||
_cloak._cloakVisualsEnabled = false;
|
_cloak._cloakVisualsEnabled = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SetReferenceFrameVolumeActive(bool active) => _cloak._referenceFrameVolume.gameObject.SetActive(active);
|
public void SetReferenceFrameVolumeActive(bool active) => _cloak._referenceFrameVolume?.gameObject.SetActive(active);
|
||||||
public void EnableReferenceFrameVolume() => SetReferenceFrameVolumeActive(true);
|
public void EnableReferenceFrameVolume() => SetReferenceFrameVolumeActive(true);
|
||||||
public void DisableReferenceFrameVolume() => SetReferenceFrameVolumeActive(false);
|
public void DisableReferenceFrameVolume() => SetReferenceFrameVolumeActive(false);
|
||||||
|
|
||||||
|
|||||||
2
NewHorizons/External/Configs/PlanetConfig.cs
vendored
2
NewHorizons/External/Configs/PlanetConfig.cs
vendored
@ -201,7 +201,7 @@ namespace NewHorizons.External.Configs
|
|||||||
|
|
||||||
if (Base.isSatellite) Base.showMinimap = false;
|
if (Base.isSatellite) Base.showMinimap = false;
|
||||||
|
|
||||||
if (!Base.hasReferenceFrame) ReferenceFrame.hideInMap = true;
|
if (!Base.hasReferenceFrame) ReferenceFrame.enabled = false;
|
||||||
|
|
||||||
if (childrenToDestroy != null) removeChildren = childrenToDestroy;
|
if (childrenToDestroy != null) removeChildren = childrenToDestroy;
|
||||||
|
|
||||||
|
|||||||
@ -10,6 +10,11 @@ namespace NewHorizons.External.Modules
|
|||||||
[JsonObject]
|
[JsonObject]
|
||||||
public class ReferenceFrameModule
|
public class ReferenceFrameModule
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Allows the object to be targeted.
|
||||||
|
/// </summary>
|
||||||
|
[DefaultValue(true)] public bool enabled = true;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Stop the object from being targeted on the map.
|
/// Stop the object from being targeted on the map.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user