requested changes

This commit is contained in:
TerrificTrifid 2025-01-05 20:26:52 -06:00
parent aaeb529eb6
commit 664eb0f2dd
3 changed files with 8 additions and 7 deletions

View File

@ -64,7 +64,7 @@ namespace NewHorizons.Builder.Body
enabled = false
};
if (belt.assetBundle != null || belt.path != null)
if (!string.IsNullOrEmpty(belt.assetBundle) || !string.IsNullOrEmpty(belt.path))
{
config.Props = new PropModule()
{

View File

@ -92,6 +92,7 @@ namespace NewHorizons.Builder.Body
LODGroup.RecalculateBounds();
// do this only for LOD because only the main body uses LOD, while title screen and proxies dont
var superGroup = planetGO.GetComponent<ProxyShadowCasterSuperGroup>();
if (superGroup != null) level2.gameObject.AddComponent<ProxyShadowCaster>()._superGroup = superGroup;
}

View File

@ -20,7 +20,7 @@ namespace NewHorizons.External.Modules
/// <summary>
/// Lowest distance from the planet asteroids can spawn
/// </summary>
[Range(0f, double.MaxValue)] public float innerRadius;
[Range(0f, float.MaxValue)] public float innerRadius;
/// <summary>
/// Angle defining the point where the belt rises up from the planet's equatorial plane if inclination is nonzero.
@ -30,19 +30,19 @@ namespace NewHorizons.External.Modules
/// <summary>
/// Maximum size of the asteroids.
/// </summary>
[Range(0f, double.MaxValue)] [DefaultValue(50)]
[Range(0f, float.MaxValue)] [DefaultValue(50)]
public float maxSize = 50f;
/// <summary>
/// Minimum size of the asteroids.
/// </summary>
[Range(0f, double.MaxValue)] [DefaultValue(20)]
[Range(0f, float.MaxValue)] [DefaultValue(20)]
public float minSize = 20;
/// <summary>
/// Greatest distance from the planet asteroids can spawn
/// </summary>
[Range(0f, double.MaxValue)] public float outerRadius;
[Range(0f, float.MaxValue)] public float outerRadius;
/// <summary>
/// How the asteroids are generated, unless you supply a detail yourself using "assetBundle" and "path"
@ -69,12 +69,12 @@ namespace NewHorizons.External.Modules
/// <summary>
/// Surface gravity of the asteroids.
/// </summary>
[Range(0f, double.MaxValue)]
[Range(0f, float.MaxValue)]
[DefaultValue(1)]
public float gravity = 1f;
/// <summary>
/// Should they be randomly oriented, or all pointing towards the center.
/// Should the detail of the asteroid be randomly oriented, or should it point towards the center.
/// </summary>
[DefaultValue(true)]
public bool randomOrientation = true;