mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
fixed node fog colors
This commit is contained in:
parent
7a6068400f
commit
e2f2ec9e5e
@ -14,7 +14,6 @@ namespace NewHorizons.Builder.Props
|
|||||||
{
|
{
|
||||||
|
|
||||||
// TODO
|
// TODO
|
||||||
//1) fix node fog color
|
|
||||||
//2) test size setting for nodes/seeds and radius for dimensions
|
//2) test size setting for nodes/seeds and radius for dimensions
|
||||||
//2) test that when a dimension has normal fog color and you shoot your probe through a seed leading to that dimension, the pictures look normal
|
//2) test that when a dimension has normal fog color and you shoot your probe through a seed leading to that dimension, the pictures look normal
|
||||||
//3) support for existing dimensions?
|
//3) support for existing dimensions?
|
||||||
@ -163,18 +162,14 @@ namespace NewHorizons.Builder.Props
|
|||||||
|
|
||||||
public static void SetNodeColors(GameObject brambleNode, Color fogTint, Color lightTint)
|
public static void SetNodeColors(GameObject brambleNode, Color fogTint, Color lightTint)
|
||||||
{
|
{
|
||||||
|
var fogRenderer = brambleNode.GetComponent<InnerFogWarpVolume>();
|
||||||
var effects = SearchUtilities.FindChild(brambleNode, "Effects");
|
var effects = SearchUtilities.FindChild(brambleNode, "Effects");
|
||||||
var fogRenderer = SearchUtilities.FindChild(effects, "InnerWarpFogSphere").GetComponent<OWRenderer>();
|
|
||||||
var lightShafts = SearchUtilities.FindChild(effects, "DB_BrambleLightShafts");
|
var lightShafts = SearchUtilities.FindChild(effects, "DB_BrambleLightShafts");
|
||||||
|
|
||||||
if (fogTint != null)
|
if (fogTint != null)
|
||||||
{
|
{
|
||||||
//var fogMeshRenderer = fogRenderer.GetComponent<MeshRenderer>();
|
fogRenderer._fogColor = fogTint;
|
||||||
//var mat = fogMeshRenderer.material;
|
fogRenderer._useFarFogColor = false;
|
||||||
//mat.color = config.fogTint.ToColor();
|
|
||||||
//fogMeshRenderer.sharedMaterial = mat;
|
|
||||||
|
|
||||||
Main.Instance.ModHelper.Events.Unity.FireInNUpdates(() => fogRenderer.SetColor(fogTint), 10);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (lightTint != null)
|
if (lightTint != null)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user