Merge pull request #253 from TerrificTrifid/dev

Various stuff
This commit is contained in:
Will Corby 2022-08-10 12:17:00 -07:00 committed by GitHub
commit a177bbffca
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
9 changed files with 324 additions and 89 deletions

View File

@ -23,7 +23,7 @@ namespace NewHorizons.Builder.Body
public static class BrambleDimensionBuilder
{
public static readonly float BASE_DIMENSION_RADIUS = 1705f;
public static readonly float BASE_DIMENSION_RADIUS = 750f;
// location of all vanilla bramble dimensions
//-9116.795 -19873.44 2480.327
@ -62,7 +62,7 @@ namespace NewHorizons.Builder.Body
var detailInfo = new PropModule.DetailInfo();
var geometry = DetailBuilder.MakeDetail(go, sector, prefab, detailInfo);
var exitWarps = SearchUtilities.Find("DB_HubDimension_Body/Sector_HubDimension/OuterWarp_Hub").InstantiateInactive();
var exitWarps = SearchUtilities.Find("DB_HubDimension_Body/Sector_HubDimension/Interactables_HubDimension/OuterWarp_Hub").InstantiateInactive();
var repelVolume = SearchUtilities.Find("DB_HubDimension_Body/BrambleRepelVolume").InstantiateInactive();
atmo.name = "Atmosphere";
@ -155,13 +155,15 @@ namespace NewHorizons.Builder.Body
// Set the scale
var scale = config.radius / BASE_DIMENSION_RADIUS;
geometry.transform.localScale = Vector3.one * scale;
sector.gameObject.GetComponent<SphereShape>().radius *= scale;
outerFogWarpVolume._warpRadius *= scale;
outerFogWarpVolume._exitRadius *= scale;
var fogGO = atmo.FindChild("FogSphere_Hub");
var fog = fogGO.GetComponent<PlanetaryFogController>();
fog._fogRadius *= scale;
fog._fogDensity *= scale;
fog._fogDensity = config.fogDensity * scale;
atmo.FindChild("FogBackdrop_Hub").transform.localScale *= scale;
var volumesShape = volumes.FindChild("ZeroG_Fluid_Audio_Volume");
var sphereShape = volumesShape.GetComponent<SphereShape>();
@ -169,17 +171,19 @@ namespace NewHorizons.Builder.Body
sphereShape.radius *= scale;
// Change fog color
if (body.Config.Bramble.dimension.fogTint != null)
if (config.fogTint != null)
{
var color = body.Config.Bramble.dimension.fogTint.ToColor();
var color = config.fogTint.ToColor();
fog.fogTint = color;
outerFogWarpVolume._fogColor = color;
}
// Set up repel volume to only contain this dimension
// Set up repel volume and cloak to scale and only contain this dimension
// The base game one is on the HUB dimension and encompasses all bramble dimensions and their sectors
var cloak = repelVolume.gameObject.GetComponentInChildren<DarkBrambleCloakSphere>();
cloak.transform.localScale = Vector3.one * 4000f;
repelVolume.GetComponent<SphereShape>().radius = 2400f * scale;
repelVolume.GetComponent<DarkBrambleRepelVolume>()._innerRadius = 2010f * scale;
var cloak = repelVolume.GetComponentInChildren<DarkBrambleCloakSphere>();
cloak.transform.localScale = Vector3.one * 4020f * scale;
cloak._sectors = new Sector[] { sector };
cloak.GetComponent<Renderer>().enabled = true;

View File

@ -175,6 +175,7 @@ namespace NewHorizons.Builder.Props
}
var innerFogWarpVolume = brambleNode.GetComponent<InnerFogWarpVolume>();
var outerFogWarpVolume = GetOuterFogWarpVolumeFromAstroObject(go);
var fogLight = brambleNode.GetComponent<FogLight>();
brambleNode.transform.parent = sector.transform;
@ -193,8 +194,6 @@ namespace NewHorizons.Builder.Props
fogLight._linkedFogLights = new List<FogLight>();
fogLight._linkedLightData = new List<FogLight.LightData>();
sector.RegisterFogLight(fogLight);
// If the config says only certain exits are allowed, enforce that
if (config.possibleExits != null)
{
@ -221,32 +220,92 @@ namespace NewHorizons.Builder.Props
// TODO: replace InnerFogWarpVolume with NHInnerFogWarpVolume, which overrides GetFogDensity to
// account for scale (this will fix the issue with screen fog caused by scaled down nodes)
// Set the scale
// Set the main scale
brambleNode.transform.localScale = Vector3.one * config.scale;
innerFogWarpVolume._warpRadius *= config.scale;
innerFogWarpVolume._exitRadius *= config.scale;
// Seed fog works differently, so it doesn't need to be fixed
// (it's also located on a different child path, so the below FindChild calls wouldn't work)
if (!config.isSeed)
// Set the seed/node specific scales and other stuff
if (config.isSeed)
{
innerFogWarpVolume._exitRadius /= 1.8f;
brambleNode.FindChild("PointLight_DB_FogLight").GetComponent<Light>().range *= config.scale;
brambleNode.FindChild("Prefab_SeedPunctureVolume (2)").GetComponent<CompoundShape>().enabled = true;
fogLight._maxVisibleDistance = float.PositiveInfinity; // Prefab does have working foglight aside from this
fogLight._minVisibleDistance *= config.scale / 15f;
}
else
{
brambleNode.FindChild("Effects/PointLight_DB_FogLight").GetComponent<Light>().range *= config.scale;
brambleNode.FindChild("Effects/FogOverrideVolume").GetComponent<FogOverrideVolume>().blendDistance *= config.scale;
fogLight._minVisibleDistance *= config.scale;
// Seed fog works differently, so it doesn't need to be fixed
// (it's also located on a different child path, so the below FindChild calls wouldn't work)
var fog = brambleNode.FindChild("Effects/InnerWarpFogSphere");
var fogMaterial = fog.GetComponent<MeshRenderer>().material;
fog.transform.localScale /= config.scale;
fogMaterial.SetFloat("_Radius", fogMaterial.GetFloat("_Radius") * config.scale);
fogMaterial.SetFloat("_Density", fogMaterial.GetFloat("_Density") / config.scale);
}
// Change the colors
if (config.isSeed) SetSeedColors(brambleNode, config.fogTint?.ToColor(), config.lightTint?.ToColor());
else SetNodeColors(brambleNode, config.fogTint?.ToColor(), config.lightTint?.ToColor());
// Set colors
Color fogTint, farFogTint, fogLightTint, lightTint, lightShaftTint, glowTint, fogOverrideTint;
innerFogWarpVolume._useFarFogColor = false;
if (config.farFogTint != null)
farFogTint = config.fogTint != null ? config.fogTint.ToColor() : new Color(1f, 0.9608f, 0.851f, 1f);
lightTint = config.lightTint != null ? config.lightTint.ToColor() : Color.white;
Color.RGBToHSV(farFogTint, out var fogH, out var fogS, out var fogV);
Color.RGBToHSV(lightTint, out var lightH, out var lightS, out var lightV);
if (config.isSeed)
{
innerFogWarpVolume._useFarFogColor = true;
innerFogWarpVolume._farFogColor = config.farFogTint.ToColor();
fogLightTint = lightTint;
fogLightTint.a = config.hasFogLight != true ? 0f : lightTint.a * 0.5f;
lightShaftTint = CalculateLightShaftTint(lightH, lightS, lightV);
lightShaftTint.a = lightTint.a;
}
else
{
fogLightTint = lightTint;
fogLightTint.a = config.hasFogLight == false || (outerFogWarpVolume == null && config.hasFogLight != true) ? 0f : lightTint.a * 0.5f;
lightShaftTint = CalculateLightShaftTint(fogH, fogS, fogV);
lightShaftTint.a = lightTint.a;
}
// Apply colors
Delay.FireOnNextUpdate(() => {
if (config.isSeed)
{
SetSeedColors(brambleNode, farFogTint, fogLightTint, lightTint, lightShaftTint);
}
else
{
// Set inner fog to destination fog tint
fogTint = AstroObjectLocator.GetAstroObject(config.linksTo).gameObject.FindChild("Sector/Atmosphere/FogSphere_Hub").GetComponent<PlanetaryFogController>().fogTint;
// Calculate glow and fog override
// Will work with any fog
Color dimFogTint;
if (go.GetComponentInChildren<PlanetaryFogController>())
{
dimFogTint = go.GetComponentInChildren<PlanetaryFogController>().fogTint;
Color.RGBToHSV(dimFogTint, out var dimH, out var dimS, out var dimV);
Color.RGBToHSV(lightShaftTint, out var shaftH, out var shaftS, out var shaftV);
glowTint = Color.HSVToRGB(shaftH, shaftS, dimV * 1.25f);
glowTint.a = lightTint.a;
fogOverrideTint = Color.HSVToRGB(fogH, Mathf.Lerp(fogS, dimS, 0.5f), Mathf.Lerp(fogV, dimV, 0.5f));
fogOverrideTint.a = 1f;
}
else
{
glowTint = fogOverrideTint = Color.clear;
}
SetNodeColors(brambleNode, fogTint, farFogTint, fogLightTint, lightTint, lightShaftTint, glowTint, fogOverrideTint);
}
});
// Set up warps
innerFogWarpVolume._sector = sector;
@ -254,7 +313,7 @@ namespace NewHorizons.Builder.Props
// the OuterFogWarpVolume of the dimension this node is inside of
// (null if this node is not inside of a bramble dimension, eg it's sitting on a planet or something)
innerFogWarpVolume._containerWarpVolume = GetOuterFogWarpVolumeFromAstroObject(go);
innerFogWarpVolume._containerWarpVolume = outerFogWarpVolume;
var success = PairEntrance(innerFogWarpVolume, config.linksTo);
if (!success) RecordUnpairedNode(innerFogWarpVolume, config.linksTo);
@ -282,60 +341,84 @@ namespace NewHorizons.Builder.Props
// Done!
brambleNode.SetActive(true);
return brambleNode;
}
public static void SetNodeColors(GameObject brambleNode, Color? fogTint, Color? lightTint)
{
if (fogTint != null)
static Color CalculateLightShaftTint(float H, float S, float V)
{
var fogRenderer = brambleNode.GetComponent<InnerFogWarpVolume>();
// Sine curve approximation shifts hue to compensate for shader shenanigans
H += -1f / 24f * Mathf.Sin(6f * Mathf.PI * H);
fogRenderer._fogColor = fogTint.Value;
// Inverted parabola is best fit for limited base game examples
S = -Mathf.Pow(S - 1f, 2f) + 1f;
var fogBackdrop = brambleNode.FindChild("Terrain_DB_BrambleSphere_Inner_v2/fogbackdrop_v2");
if (fogBackdrop != null)
fogBackdrop.GetComponent<MeshRenderer>().material.color = fogTint.Value;
}
if (lightTint != null)
{
var lightShafts = brambleNode.FindChild("Effects/DB_BrambleLightShafts");
var lightShaft1 = lightShafts.FindChild("BrambleLightShaft1");
var mat = lightShaft1.GetComponent<MeshRenderer>().material;
mat.color = lightTint.Value;
for (int i = 1; i <= 6; i++)
{
var lightShaft = lightShafts.FindChild($"BrambleLightShaft{i}");
lightShaft.GetComponent<MeshRenderer>().sharedMaterial = mat;
}
return Color.HSVToRGB(H, S, V);
}
}
public static void SetSeedColors(GameObject brambleSeed, Color? fogTint, Color? lightTint)
public static void SetNodeColors(GameObject brambleNode, Color fogTint, Color farFogTint, Color fogLightTint, Color lightTint, Color lightShaftTint, Color glowTint, Color fogOverrideTint)
{
if (fogTint != null)
{
var fogRenderer = brambleSeed.FindChild("VolumetricFogSphere (2)");
var innerFogWarpVolume = brambleNode.GetComponent<InnerFogWarpVolume>();
innerFogWarpVolume._fogColor = fogTint;
innerFogWarpVolume._farFogColor = farFogTint;
var fogMeshRenderer = fogRenderer.GetComponent<MeshRenderer>();
fogMeshRenderer.material.color = fogTint.Value;
var fogLight = brambleNode.GetComponent<FogLight>();
fogLight._maxAlpha = fogLightTint.a;
fogLight._primaryLightData.maxAlpha = fogLightTint.a;
fogLight._tint = fogLightTint;
fogLight._primaryLightData.color = fogLightTint;
var light = brambleNode.FindChild("Effects/PointLight_DB_FogLight").GetComponent<Light>();
light.intensity = lightTint.a * 0.7f;
light.color = lightTint;
var lightShafts = brambleNode.FindChild("Effects/DB_BrambleLightShafts");
var lightShaft1 = lightShafts.FindChild("BrambleLightShaft1");
var mat = lightShaft1.GetComponent<MeshRenderer>().material;
mat.color = lightShaftTint;
for (int i = 1; i <= 6; i++)
{
var lightShaft = lightShafts.FindChild($"BrambleLightShaft{i}");
lightShaft.GetComponent<MeshRenderer>().sharedMaterial = mat;
}
if (lightTint != null)
var glow = brambleNode.FindChild("Effects/InnerWarpFogGlow");
glow.GetComponent<MeshRenderer>().material.color = glowTint;
glow.transform.localScale *= glowTint.a;
if (glowTint.a == 0f) glow.SetActive(false);
var fogOverride = brambleNode.FindChild("Effects/FogOverrideVolume");
if (fogOverrideTint.a == 1f) // Override turns goofy if alpha isn't 1
{
var lightShafts = brambleSeed.FindChild("Terrain_DB_BrambleSphere_Seed_V2 (2)/DB_SeedLightShafts");
var volume = fogOverride.GetComponent<FogOverrideVolume>();
volume.tint = fogOverrideTint;
volume.blendDistance *= lightTint.a;
volume.radius *= lightTint.a;
}
else fogOverride.SetActive(false);
}
var lightShaft1 = lightShafts.FindChild("DB_SeedLightShafts1");
var mat = lightShaft1.GetComponent<MeshRenderer>().material;
mat.color = lightTint.Value;
public static void SetSeedColors(GameObject brambleSeed, Color farFogTint, Color fogLightTint, Color lightTint, Color lightShaftTint)
{
brambleSeed.GetComponent<InnerFogWarpVolume>()._fogColor = farFogTint;
brambleSeed.FindChild("VolumetricFogSphere (2)").GetComponent<MeshRenderer>().material.color = new Color(farFogTint.r * 10, farFogTint.g * 10, farFogTint.b * 10, farFogTint.a);
for (int i = 1; i <= 6; i++)
{
var lightShaft = lightShafts.FindChild($"DB_SeedLightShafts{i}");
lightShaft.GetComponent<MeshRenderer>().sharedMaterial = mat;
}
var fogLight = brambleSeed.GetComponent<FogLight>();
fogLight._maxAlpha = fogLightTint.a;
fogLight._primaryLightData.maxAlpha = fogLightTint.a;
fogLight._tint = fogLightTint;
fogLight._primaryLightData.color = fogLightTint;
var light = brambleSeed.FindChild("PointLight_DB_FogLight").GetComponent<Light>();
light.intensity = lightTint.a;
light.color = lightTint;
var lightShafts = brambleSeed.FindChild("Terrain_DB_BrambleSphere_Seed_V2 (2)/DB_SeedLightShafts");
var lightShaft1 = lightShafts.FindChild("DB_SeedLightShafts1");
var mat = lightShaft1.GetComponent<MeshRenderer>().material;
mat.color = lightShaftTint;
for (int i = 1; i <= 6; i++)
{
var lightShaft = lightShafts.FindChild($"DB_SeedLightShafts{i}");
lightShaft.GetComponent<MeshRenderer>().sharedMaterial = mat;
}
}
}

View File

@ -24,9 +24,25 @@ namespace NewHorizons.Builder.Props
var up = planetGO.transform.TransformPoint(pos) - planetGO.transform.position;
geyserGO.transform.rotation = Quaternion.FromToRotation(geyserGO.transform.up, up) * geyserGO.transform.rotation;
if (info.disableBubbles) geyserGO.FindChild("GeyserParticles/GeyserBubbles").SetActive(false);
if (info.disableShaft) geyserGO.FindChild("GeyserParticles/GeyserShaft").SetActive(false);
if (info.disableSpout) geyserGO.FindChild("GeyserParticles/GeyserSpout").SetActive(false);
var bubbles = geyserGO.FindChild("GeyserParticles/GeyserBubbles");
var shaft = geyserGO.FindChild("GeyserParticles/GeyserShaft");
var spout = geyserGO.FindChild("GeyserParticles/GeyserSpout");
if (info.tint != null)
{
var tint = info.tint.ToColor();
bubbles.GetComponent<ParticleSystemRenderer>().material.color = new Color(tint.r, tint.g, tint.b, Mathf.LerpUnclamped(0.5f, 1f, tint.a)); //bubbles disappear at 0.5 alpha
shaft.GetComponent<ParticleSystemRenderer>().material.color = tint;
spout.GetComponent<ParticleSystemRenderer>().material.color = tint;
}
if (info.disableBubbles) bubbles.SetActive(false);
if (info.disableShaft) shaft.SetActive(false);
if (info.disableSpout) spout.SetActive(false);
var geyserController = geyserGO.GetComponent<GeyserController>();
geyserController._activeDuration = info.activeDuration;
geyserController._inactiveDuration = info.inactiveDuration;
geyserGO.SetActive(true);
@ -35,8 +51,40 @@ namespace NewHorizons.Builder.Props
// Do this after awake
Delay.FireOnNextUpdate(() => geyserFluidVolume._maxHeight = 1);
geyserFluidVolume.enabled = true; // why do we enable this? idk
geyserFluidVolume.GetComponent<CapsuleShape>().enabled = true; // i think this is already enabled but wtv
if (info.force == 0f) geyserFluidVolume.enabled = false;
else
{
geyserFluidVolume.enabled = true; // why do we enable this? idk
geyserFluidVolume.GetComponent<CapsuleShape>().enabled = true; // i think this is already enabled but wtv
geyserFluidVolume._attractionalFlowSpeed *= info.force / 55f;
geyserFluidVolume._directionalFlowSpeed = info.force;
}
geyserGO.GetComponent<GeyserAudioController>().SetSector(sector);
var oneShotAudio = geyserGO.FindChild("Geyser_OneShotAudioSrc");
var loopAudio = geyserGO.FindChild("Geyser_LoopAudioSrc");
oneShotAudio.GetComponent<AudioSpreadController>().SetSector(sector);
loopAudio.GetComponent<AudioSpreadController>().SetSector(sector);
Delay.FireOnNextUpdate(() => {
if (info.volume == 0)
{
oneShotAudio.SetActive(false);
loopAudio.SetActive(false);
}
else
{
oneShotAudio.GetComponent<OWAudioSource>().SetMaxVolume(info.volume);
loopAudio.GetComponent<OWAudioSource>().SetMaxVolume(info.volume);
}
});
// If it starts at the shaft, move the start/end sounds to it
if ((info.disableSpout && !info.disableShaft) || info.offset == -67f)
{
oneShotAudio.transform.SetLocalPositionY(67f);
}
}
}
}

View File

@ -82,7 +82,7 @@ namespace NewHorizons.Builder.Props
_computerPrefab.name = "Prefab_NOM_Computer";
_computerPrefab.transform.rotation = Quaternion.identity;
_preCrashComputerPrefab = SearchUtilities.Find("DB_EscapePodDimension_Body/Sector_EscapePodDimension/Sector_EscapePodBody/Interactables_EscapePodBody/Prefab_NOM_Vessel_Computer").InstantiateInactive();
_preCrashComputerPrefab = SearchUtilities.Find("BrittleHollow_Body/Sector_BH/Sector_EscapePodCrashSite/Sector_CrashFragment/EscapePod_Socket/Interactibles_EscapePod/Prefab_NOM_Vessel_Computer").InstantiateInactive();
_preCrashComputerPrefab.name = "Prefab_NOM_Vessel_Computer";
_preCrashComputerPrefab.transform.rotation = Quaternion.identity;
@ -305,9 +305,6 @@ namespace NewHorizons.Builder.Props
if (info.normal != null) up = planetGO.transform.TransformDirection(info.normal);
computerObject.transform.rotation = Quaternion.FromToRotation(Vector3.up, up) * computerObject.transform.rotation;
// Move it slightly up more
computerObject.transform.position += up.normalized * 0.1f;
var computer = computerObject.GetComponent<NomaiVesselComputer>();
computer.SetSector(sector);
@ -317,6 +314,15 @@ namespace NewHorizons.Builder.Props
computer._nomaiTextAsset.name = Path.GetFileNameWithoutExtension(info.xmlFile);
AddTranslation(xmlPath);
// Make fifth ring work
var fifthRingObject = computerObject.FindChild("Props_NOM_Vessel_Computer 1/Props_NOM_Vessel_Computer_Effects (4)");
fifthRingObject.SetActive(true);
var fifthRing = fifthRingObject.GetComponent<NomaiVesselComputerRing>();
//fifthRing._baseProjectorColor = new Color(1.4118, 1.5367, 4, 1);
//fifthRing._baseTextColor = new Color(0.8824, 0.9604, 2.5, 1);
//fifthRing._baseTextShadowColor = new Color(0.3529, 0.3843, 1, 0.25);
fifthRing._computer = computer;
computerObject.SetActive(true);
// All rings are rendered by detail builder so dont do that (have to wait for entries to be set)

View File

@ -32,15 +32,20 @@ namespace NewHorizons.External.Modules
/// </summary>
public MColor fogTint;
/// <summary>
/// The density of the fog inside this dimension. The default is 6.
/// </summary>
[DefaultValue(6f)] public float fogDensity = 6f;
/// <summary>
/// The name of the *node* that the player is taken to when exiting this dimension.
/// </summary>
public string linksTo;
/// <summary>
/// The internal radius (in meters) of the dimension. The default is 1705.
/// The internal radius (in meters) of the dimension. The default is 750 for the Hub, Escape Pod, and Angler Nest dimensions, and 500 for the others.
/// </summary>
[DefaultValue(1705f)] public float radius = 1705f;
[DefaultValue(750f)] public float radius = 750f;
/// <summary>
/// An array of integers from 0-5. By default, all entrances are allowed. To force this dimension to warp players in from only one point (like the anglerfish nest dimension in the base game) set this value to [3], [5], or similar. Values of 0-5 only.
@ -63,7 +68,8 @@ namespace NewHorizons.External.Modules
public MVector3 rotation;
/// <summary>
/// The physical scale of the node, as a multiplier of the original size
/// The physical scale of the node, as a multiplier of the original size.
/// Nodes are 150m across, seeds are 10m across.
/// </summary>
[DefaultValue(1f)] public float scale = 1f;
@ -83,24 +89,34 @@ namespace NewHorizons.External.Modules
[DefaultValue(false)] public bool isSeed = false;
/// <summary>
/// The color of the fog inside the node. Leave blank for the default yellowish color: (131, 124, 105, 255)
/// The color of the fog inside the node.
/// Leave blank for the default yellowish white color: (255, 245, 217, 255)
/// </summary>
public MColor fogTint;
/// <summary>
/// The color of the shafts of light coming from the entrances to the node. Leave blank for the default yellowish color: (131, 124, 105, 255)
/// The color of the light from the node. Alpha controls brightness.
/// Leave blank for the default white color.
/// </summary>
public MColor lightTint;
/// <summary>
/// The color a dimension's background fog turns when you approach this node (if it's in a dimension). If this node is not in a dimension, this does nothing. Leave blank for the default yellowish white color: (255, 245, 217, 255)
/// Should this node have a point of light from afar?
/// By default, nodes will have a foglight, while seeds won't, and neither will if not in a dimension.
/// </summary>
public MColor farFogTint;
public bool? hasFogLight;
/// <summary>
/// An array of integers from 0-5. By default, all exits are allowed. To force this node to warp players out from only one hole set this value to [3], [5], or similar. Values of 0-5 only.
/// </summary>
public int[] possibleExits;
#region Obsolete
[Obsolete("farFogTint is deprecated, please use fogTint instead")]
public MColor farFogTint;
#endregion Obsolete
}
}
}

View File

@ -234,10 +234,35 @@ namespace NewHorizons.External.Modules
/// </summary>
[DefaultValue(-97.5f)] public float offset = -97.5f;
/// <summary>
/// Force of the geyser on objects
/// </summary>
[DefaultValue(55f)] public float force = 55f;
/// <summary>
/// Time in seconds eruptions last for
/// </summary>
[DefaultValue(10f)] public float activeDuration = 10f;
/// <summary>
/// Time in seconds between eruptions
/// </summary>
[DefaultValue(19f)] public float inactiveDuration = 19f;
/// <summary>
/// Color of the geyser. Alpha sets the particle density.
/// </summary>
public MColor tint;
/// <summary>
/// Disable the individual particle systems of the geyser
/// </summary>
public bool disableBubbles, disableShaft, disableSpout;
/// <summary>
/// Loudness of the geyser
/// </summary>
[DefaultValue(0.7f)] public float volume = 0.7f;
}
[JsonObject]

View File

@ -67,8 +67,9 @@ namespace NewHorizons.Handlers
lightGO.transform.parent = SearchUtilities.Find("Scene/Background").transform;
lightGO.transform.localPosition = new Vector3(-47.9203f, 145.7596f, 43.1802f);
var light = lightGO.AddComponent<Light>();
light.color = new Color(1f, 1f, 1f, 1f);
light.range = 100;
light.type = LightType.Directional;
light.color = Color.white;
light.range = float.PositiveInfinity;
light.intensity = 0.8f;
}

View File

@ -536,15 +536,21 @@
"description": "The color of the fog inside this dimension. Leave blank for the default yellowish color: (113, 107, 81)",
"$ref": "#/definitions/MColor"
},
"fogDensity": {
"type": "number",
"description": "The density of the fog inside this dimension. The default is 6.",
"format": "float",
"default": 6.0
},
"linksTo": {
"type": "string",
"description": "The name of the *node* that the player is taken to when exiting this dimension."
},
"radius": {
"type": "number",
"description": "The internal radius (in meters) of the dimension. The default is 1705.",
"description": "The internal radius (in meters) of the dimension. The default is 750 for the Hub, Escape Pod, and Angler Nest dimensions, and 500 for the others.",
"format": "float",
"default": 1705.0
"default": 750.0
},
"allowedEntrances": {
"type": "array",
@ -570,7 +576,7 @@
},
"scale": {
"type": "number",
"description": "The physical scale of the node, as a multiplier of the original size",
"description": "The physical scale of the node, as a multiplier of the original size. \nNodes are 150m across, seeds are 10m across.",
"format": "float",
"default": 1.0
},
@ -588,16 +594,19 @@
"default": false
},
"fogTint": {
"description": "The color of the fog inside the node. Leave blank for the default yellowish color: (131, 124, 105, 255)",
"description": "The color of the fog inside the node. \nLeave blank for the default yellowish white color: (255, 245, 217, 255)",
"$ref": "#/definitions/MColor"
},
"lightTint": {
"description": "The color of the shafts of light coming from the entrances to the node. Leave blank for the default yellowish color: (131, 124, 105, 255)",
"description": "The color of the light from the node. Alpha controls brightness.\nLeave blank for the default white color.",
"$ref": "#/definitions/MColor"
},
"farFogTint": {
"description": "The color a dimension's background fog turns when you approach this node (if it's in a dimension). If this node is not in a dimension, this does nothing. Leave blank for the default yellowish white color: (255, 245, 217, 255)",
"$ref": "#/definitions/MColor"
"hasFogLight": {
"type": [
"boolean",
"null"
],
"description": "Should this node have a point of light from afar? \nBy default, nodes will have a foglight, while seeds won't, and neither will if not in a dimension."
},
"possibleExits": {
"type": "array",
@ -1110,6 +1119,28 @@
"format": "float",
"default": -97.5
},
"force": {
"type": "number",
"description": "Force of the geyser on objects",
"format": "float",
"default": 55.0
},
"activeDuration": {
"type": "number",
"description": "Time in seconds eruptions last for",
"format": "float",
"default": 10.0
},
"inactiveDuration": {
"type": "number",
"description": "Time in seconds between eruptions",
"format": "float",
"default": 19.0
},
"tint": {
"description": "Color of the geyser. Alpha sets the particle density.",
"$ref": "#/definitions/MColor"
},
"disableBubbles": {
"type": "boolean",
"description": "Disable the individual particle systems of the geyser"
@ -1121,6 +1152,12 @@
"disableSpout": {
"type": "boolean",
"description": "Disable the individual particle systems of the geyser"
},
"volume": {
"type": "number",
"description": "Loudness of the geyser",
"format": "float",
"default": 0.7
}
}
},

View File

@ -0,0 +1,15 @@
---
Title: Bramble Colors
Render_TOC: False
---
| Dimension | Fog color | Node fog color |
|-------------|------------------------------------------|------------------------------------------|
| Cluster | {"r": 126, "g": 119, "b": 101, "a": 255} | {"r": 255, "g": 245, "b": 217, "a": 255} |
| Vessel | {"r": 206, "g": 187, "b": 137, "a": 255} | {"r": 191, "g": 171, "b": 133, "a": 255} |
| Small Nest | {"r": 131, "g": 128, "b": 121, "a": 255} | {"r": 255, "g": 245, "b": 217, "a": 255} |
| Pioneer | {"r": 106, "g": 116, "b": 99, "a": 255} | {"r": 255, "g": 245, "b": 217, "a": 255} |
| Hub | {"r": 84, "g": 83, "b": 73, "a": 255} | {"r": 84, "g": 83, "b": 73, "a": 255} |
| Exit Only | {"r": 113, "g": 107, "b": 81, "a": 255} | {"r": 255, "g": 245, "b": 217, "a": 255} |
| Escape Pod | {"r": 83, "g": 99, "b": 87, "a": 255} | {"r": 255, "g": 245, "b": 217, "a": 255} |
| Angler Nest | {"r": 113, "g": 107, "b": 81, "a": 255} | {"r": 255, "g": 129, "b": 83, "a": 255} |