mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
Creation handler
This commit is contained in:
parent
5b9809f041
commit
6442f6bb22
@ -5,7 +5,7 @@ namespace NewHorizons.Builder.General
|
||||
{
|
||||
public static class AmbientLightBuilder
|
||||
{
|
||||
public static Light Make(GameObject planetGO, Sector sector, AmbientLightModule config)
|
||||
public static Light Make(GameObject planetGO, Sector sector, AmbientLightModule config, float surfaceSize)
|
||||
{
|
||||
var ambientLight = Main.Instance.CurrentStarSystem == "EyeOfTheUniverse" ? SearchUtilities.Find("EyeOfTheUniverse_Body/Sector_EyeOfTheUniverse/SixthPlanet_Root/QuantumMoonProxy_Pivot/QuantumMoonProxy_Root/MoonState_Root/AmbientLight_QM") : SearchUtilities.Find("QuantumMoon_Body/AmbientLight_QM");
|
||||
if (ambientLight == null) return null;
|
||||
|
||||
@ -498,9 +498,10 @@ namespace NewHorizons.Handlers
|
||||
var sphereOfInfluence = GetSphereOfInfluence(body);
|
||||
|
||||
Light[] ambientLight = null;
|
||||
if (body.Config.Base.ambientLight != 0)
|
||||
if (body.Config.AmbientLights != null)
|
||||
{
|
||||
ambientLight = AmbientLightBuilder.Make(go, sector, sphereOfInfluence, body.Config.Base.ambientLight);
|
||||
ambientLight = new Light[0];
|
||||
foreach (var light in body.Config.AmbientLights) ambientLight.Append(AmbientLightBuilder.Make(go, sector, light, body.Config.Base.surfaceSize)).ToArray();
|
||||
}
|
||||
|
||||
if (body.Config.Base.groundSize != 0)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user