1752 lines
65 KiB
C#
1752 lines
65 KiB
C#
using UnityEngine;
|
|
|
|
namespace Artngame.SKYMASTER
|
|
{
|
|
public class SKYMASTER_API_5_0 : MonoBehaviour
|
|
{
|
|
public bool tempBased;
|
|
|
|
private bool volumeClouds1 = true;
|
|
|
|
private bool volumeClouds2;
|
|
|
|
public CloudScript volumeClouds2SCRIPT;
|
|
|
|
public WeatherScript WeatherPatternSCRIPT;
|
|
|
|
public CloudScript volumeClouds2SCRIPT_REFL;
|
|
|
|
public GameObject Volcano;
|
|
|
|
public GameObject Caustics;
|
|
|
|
public float min_height = -16f;
|
|
|
|
private bool cloudPresets;
|
|
|
|
public bool EnablecloudPresets;
|
|
|
|
public Texture2D cloudsAPic0;
|
|
|
|
public Texture2D cloudsAPic1;
|
|
|
|
public Texture2D cloudsAPic2;
|
|
|
|
public Texture2D cloudsAPic3;
|
|
|
|
public Texture2D cloudsAPic4;
|
|
|
|
public Texture2D cloudsBPic0;
|
|
|
|
public Texture2D cloudsBPic1;
|
|
|
|
public Texture2D cloudsBPic2;
|
|
|
|
public GameObject Terra1;
|
|
|
|
public Material DropletsMat;
|
|
|
|
public GameObject Abomb;
|
|
|
|
private float last_bomb_time = -8f;
|
|
|
|
public GameObject Rain2;
|
|
|
|
public GameObject Bats;
|
|
|
|
public GameObject Leaves;
|
|
|
|
public GameObject Floor;
|
|
|
|
public GameObject Floor_stripes;
|
|
|
|
public GameObject Floor_collider;
|
|
|
|
private bool Special_effects;
|
|
|
|
private bool Rain2_on;
|
|
|
|
private bool Leaves_on;
|
|
|
|
private bool Bats_on;
|
|
|
|
public Transform PointLights;
|
|
|
|
public Transform PointLightsCin;
|
|
|
|
public Transform Camera1;
|
|
|
|
public Transform Camera2;
|
|
|
|
public Flare FlareTexture;
|
|
|
|
public CloudHandlerSM CloudHandler;
|
|
|
|
public Transform TinyPlanet;
|
|
|
|
public Transform Pillars;
|
|
|
|
public float Sun_time_start = 14.43f;
|
|
|
|
public GameObject SKYMASTER_OBJ;
|
|
|
|
private SkyMasterManager SUNMASTER;
|
|
|
|
public GameObject SUNMASTERA;
|
|
|
|
public GameObject SUNMASTERB;
|
|
|
|
public SkyMasterManager SUNMASTERAH;
|
|
|
|
public SkyMasterManager SUNMASTERBH;
|
|
|
|
public bool HUD_ON = true;
|
|
|
|
private bool set_sun_start;
|
|
|
|
private float Dome_rot;
|
|
|
|
private float Camera_up;
|
|
|
|
private float TOD;
|
|
|
|
private float SPEED;
|
|
|
|
private WaterHeightSM WaterHeightHandle;
|
|
|
|
private WaterHandlerSM WaterHandler;
|
|
|
|
private int windowsON;
|
|
|
|
public Transform windowsSpot;
|
|
|
|
public Transform underwaterSpot;
|
|
|
|
public Transform AtollViewSpot;
|
|
|
|
public Transform oceanSpot;
|
|
|
|
public Transform boatSpot;
|
|
|
|
public Transform boatSpot2;
|
|
|
|
public Transform smokeSPOT;
|
|
|
|
public GameObject farOceanplane;
|
|
|
|
private bool offsetsON;
|
|
|
|
private bool colorsON;
|
|
|
|
public GameObject ParticleClouds;
|
|
|
|
public GameObject ParticleCloudsA;
|
|
|
|
public GameObject ParticleCloudsB;
|
|
|
|
public GameObject skyA;
|
|
|
|
public GameObject skyB;
|
|
|
|
private int VolCloud;
|
|
|
|
private bool made_once;
|
|
|
|
private bool made_onceB;
|
|
|
|
private int activeSky;
|
|
|
|
private int prevSky;
|
|
|
|
private bool CinemaLook;
|
|
|
|
private bool Freezeme;
|
|
|
|
private GlobalFogSkyMaster Fog;
|
|
|
|
private int limitRef;
|
|
|
|
private float humidity = 45f;
|
|
|
|
private float temperature = 25f;
|
|
|
|
public float highTemperature = 10f;
|
|
|
|
public float HighHumidity = 55f;
|
|
|
|
private bool enableCirrus;
|
|
|
|
private bool enableStratus;
|
|
|
|
private bool enable2DStratus;
|
|
|
|
private bool enableCumulus;
|
|
|
|
private bool changedWeather;
|
|
|
|
private float changedWeatherTime;
|
|
|
|
public float weatherChangeDelay = 14f;
|
|
|
|
private float prev_ambient;
|
|
|
|
private void ApplyType0Scatter()
|
|
{
|
|
SUNMASTERAH.VolCloudTransp = 0f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensitySunOffset = -0.11f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityDiffOffset = -0.03f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityFogOffset = -12f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadScale.y = 3f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.x = 1005f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.y = 1f;
|
|
SUNMASTERAH.VolShaderCloudsH.ClearDayHorizon = 0.1f;
|
|
SUNMASTERAH.VolShaderCloudsH.ClearDayCoverage = -0.22f;
|
|
SUNMASTERAH.VolShaderCloudsH.CloudDensity = 0.0001f;
|
|
Vector3 eulerAngles = SUNMASTERAH.VolShaderCloudsH.SideClouds.eulerAngles;
|
|
SUNMASTERAH.VolShaderCloudsH.SideClouds.eulerAngles = new Vector3(2f, eulerAngles.y, eulerAngles.z);
|
|
}
|
|
|
|
private void ApplyType0Default()
|
|
{
|
|
SUNMASTERAH.VolCloudTransp = 0.37f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensitySunOffset = -0.05f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityDiffOffset = -0.02f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityFogOffset = 0f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadScale.y = 3f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.x = 1005f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.y = 1f;
|
|
SUNMASTERAH.VolShaderCloudsH.ClearDayHorizon = 0.28f;
|
|
SUNMASTERAH.VolShaderCloudsH.ClearDayCoverage = -0.22f;
|
|
SUNMASTERAH.VolShaderCloudsH.CloudDensity = 0.0001f;
|
|
Vector3 eulerAngles = SUNMASTERAH.VolShaderCloudsH.SideClouds.eulerAngles;
|
|
SUNMASTERAH.VolShaderCloudsH.SideClouds.eulerAngles = new Vector3(6f, eulerAngles.y, eulerAngles.z);
|
|
}
|
|
|
|
private void ApplyType0Default1()
|
|
{
|
|
SUNMASTERAH.VolCloudTransp = 0.37f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensitySunOffset = -0.05f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityDiffOffset = -0.02f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityFogOffset = -9f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadScale.y = 3f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.x = 1005f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.y = 1f;
|
|
SUNMASTERAH.VolShaderCloudsH.ClearDayHorizon = 0.01f;
|
|
SUNMASTERAH.VolShaderCloudsH.ClearDayCoverage = -0.22f;
|
|
SUNMASTERAH.VolShaderCloudsH.CloudDensity = 0.00012f;
|
|
Vector3 eulerAngles = SUNMASTERAH.VolShaderCloudsH.SideClouds.eulerAngles;
|
|
SUNMASTERAH.VolShaderCloudsH.SideClouds.eulerAngles = new Vector3(0f, eulerAngles.y, eulerAngles.z);
|
|
}
|
|
|
|
private void ApplyType0Default2()
|
|
{
|
|
SUNMASTERAH.VolCloudTransp = 0.7f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensitySunOffset = -0.04f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityDiffOffset = -0.02f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityFogOffset = -3f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadScale.y = 2f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.x = 992f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.y = 1f;
|
|
SUNMASTERAH.VolShaderCloudsH.ClearDayHorizon = 0.05f;
|
|
SUNMASTERAH.VolShaderCloudsH.ClearDayCoverage = -0.19f;
|
|
SUNMASTERAH.VolShaderCloudsH.CloudDensity = 0.0002f;
|
|
Vector3 eulerAngles = SUNMASTERAH.VolShaderCloudsH.SideClouds.eulerAngles;
|
|
SUNMASTERAH.VolShaderCloudsH.SideClouds.eulerAngles = new Vector3(6f, eulerAngles.y, eulerAngles.z);
|
|
}
|
|
|
|
private void ApplyType0Default3()
|
|
{
|
|
SUNMASTERAH.VolCloudTransp = 0.3f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensitySunOffset = -0.22f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityDiffOffset = -0.15f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityFogOffset = -9f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadScale.y = 3f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.x = 1020f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.y = 1f;
|
|
SUNMASTERAH.VolShaderCloudsH.ClearDayHorizon = 0.01f;
|
|
SUNMASTERAH.VolShaderCloudsH.ClearDayCoverage = -0.2f;
|
|
SUNMASTERAH.VolShaderCloudsH.CloudDensity = 0.00015f;
|
|
Vector3 eulerAngles = SUNMASTERAH.VolShaderCloudsH.SideClouds.eulerAngles;
|
|
SUNMASTERAH.VolShaderCloudsH.SideClouds.eulerAngles = new Vector3(0f, eulerAngles.y, eulerAngles.z);
|
|
}
|
|
|
|
private void ApplyType0Default4()
|
|
{
|
|
SUNMASTERAH.VolCloudTransp = 0.9f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensitySunOffset = -0.4f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityDiffOffset = -0.05f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityFogOffset = -9.5f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadScale.y = 2.8f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.x = 1030f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.y = 1f;
|
|
SUNMASTERAH.VolShaderCloudsH.ClearDayHorizon = 0.01f;
|
|
SUNMASTERAH.VolShaderCloudsH.ClearDayCoverage = -0.22f;
|
|
SUNMASTERAH.VolShaderCloudsH.CloudDensity = 0.00018f;
|
|
Vector3 eulerAngles = SUNMASTERAH.VolShaderCloudsH.SideClouds.eulerAngles;
|
|
SUNMASTERAH.VolShaderCloudsH.SideClouds.eulerAngles = new Vector3(0f, eulerAngles.y, eulerAngles.z);
|
|
}
|
|
|
|
private void ApplyType1Default()
|
|
{
|
|
SUNMASTERAH.VolCloudTransp = 0.6f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensitySunOffset = -0f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityDiffOffset = -0f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityFogOffset = -0f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadScale.y = 1.4f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.x = 1000f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.y = 1f;
|
|
SUNMASTERAH.VolShaderCloudsH.UpdateScatterShader = true;
|
|
SUNMASTERAH.VolShaderCloudsH.fog_depth = 0.39f;
|
|
SUNMASTERAH.VolShaderCloudsH.reileigh = 7.48f;
|
|
SUNMASTERAH.VolShaderCloudsH.mieCoefficient = 0.01f;
|
|
SUNMASTERAH.VolShaderCloudsH.mieDirectionalG = 0.41f;
|
|
SUNMASTERAH.VolShaderCloudsH.ExposureBias = 0.04f;
|
|
SUNMASTERAH.VolShaderCloudsH.K = new Vector3(1f, 0.5f, 0.5f);
|
|
}
|
|
|
|
private void ApplyType1Default1()
|
|
{
|
|
SUNMASTERAH.VolCloudTransp = 0.6f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensitySunOffset = -0f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityDiffOffset = -0f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityFogOffset = -0f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadScale.y = 1.4f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.x = 1000f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.y = 1f;
|
|
SUNMASTERAH.VolShaderCloudsH.UpdateScatterShader = false;
|
|
SUNMASTERAH.VolShaderCloudsH.fog_depth = 0.39f;
|
|
SUNMASTERAH.VolShaderCloudsH.reileigh = 7.48f;
|
|
SUNMASTERAH.VolShaderCloudsH.mieCoefficient = 0.01f;
|
|
SUNMASTERAH.VolShaderCloudsH.mieDirectionalG = 0.6f;
|
|
SUNMASTERAH.VolShaderCloudsH.ExposureBias = 0.02f;
|
|
SUNMASTERAH.VolShaderCloudsH.K = new Vector3(111f, 1f, 1f);
|
|
}
|
|
|
|
private void ApplyType1Default2()
|
|
{
|
|
SUNMASTERAH.VolCloudTransp = 0.7f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensitySunOffset = -0.05f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityDiffOffset = 0.04f;
|
|
SUNMASTERAH.VolShaderCloudsH.IntensityFogOffset = -0f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadScale.y = 2.8f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.x = 700f;
|
|
SUNMASTERAH.VolShaderCloudsH.MultiQuadHeights.y = 1f;
|
|
SUNMASTERAH.VolShaderCloudsH.ClearDayHorizon = 0.01f;
|
|
SUNMASTERAH.VolShaderCloudsH.UpdateScatterShader = false;
|
|
SUNMASTERAH.VolShaderCloudsH.fog_depth = 0.39f;
|
|
SUNMASTERAH.VolShaderCloudsH.reileigh = 7.48f;
|
|
SUNMASTERAH.VolShaderCloudsH.mieCoefficient = 0.01f;
|
|
SUNMASTERAH.VolShaderCloudsH.mieDirectionalG = 0.6f;
|
|
SUNMASTERAH.VolShaderCloudsH.ExposureBias = 0.02f;
|
|
SUNMASTERAH.VolShaderCloudsH.K = new Vector3(111f, 1f, 1f);
|
|
}
|
|
|
|
private void ApplyType1Default3()
|
|
{
|
|
}
|
|
|
|
private void Disable_all()
|
|
{
|
|
if (Leaves.activeInHierarchy)
|
|
{
|
|
Leaves.SetActive(value: false);
|
|
}
|
|
if (Bats.activeInHierarchy)
|
|
{
|
|
Bats.SetActive(value: false);
|
|
}
|
|
if (Rain2.activeInHierarchy)
|
|
{
|
|
Rain2.SetActive(value: false);
|
|
}
|
|
}
|
|
|
|
private void Start()
|
|
{
|
|
if (SKYMASTER_OBJ != null)
|
|
{
|
|
SUNMASTER = SKYMASTER_OBJ.GetComponent(typeof(SkyMasterManager)) as SkyMasterManager;
|
|
}
|
|
SPEED = SUNMASTER.SPEED;
|
|
SUNMASTER.Seasonal_change_auto = false;
|
|
TOD = SUNMASTER.Current_Time;
|
|
WaterHeightHandle = SUNMASTER.water.gameObject.GetComponent<WaterHeightSM>();
|
|
WaterHandler = SUNMASTER.water.gameObject.GetComponent<WaterHandlerSM>();
|
|
Dome_rot = SUNMASTER.Rot_Sun_Y;
|
|
SUNMASTERAH = SUNMASTERA.GetComponent<SkyMasterManager>();
|
|
SUNMASTERBH = SUNMASTERB.GetComponent<SkyMasterManager>();
|
|
if (CloudHandler.MultiQuadCClouds)
|
|
{
|
|
SUNMASTERAH.ApplyType0Scatter(SUNMASTERAH);
|
|
}
|
|
}
|
|
|
|
private void OnGUI()
|
|
{
|
|
float num = 100f;
|
|
float num2 = 30f;
|
|
if (tempBased)
|
|
{
|
|
GUI.TextArea(new Rect(2f * (num + 10f), 1f * num2, num + 0f, 20f), "SkyDome rot");
|
|
Dome_rot = GUI.HorizontalSlider(new Rect(2f * (num + 10f), 1f * num2 + 25f, num + 0f, 30f), Dome_rot, 0f, 360f);
|
|
SUNMASTER.Rot_Sun_Y = Dome_rot;
|
|
GUI.TextArea(new Rect(0f * num + 10f, 6f, num * 2f, 22f), "Weather Severity:" + SUNMASTER.WeatherSeverity);
|
|
GUI.TextArea(new Rect(0f * num + 10f, num2, num * 1f, 22f), "Humidity:" + humidity);
|
|
humidity = GUI.VerticalSlider(new Rect(0f * num + 10f, num2 + 30f, num * 1f, 132f), humidity, 100f, 0f);
|
|
GUI.TextArea(new Rect(1f * num + 10f, num2, num * 1f, 22f), "Temperature:" + temperature);
|
|
temperature = GUI.VerticalSlider(new Rect(1f * num + 10f, num2 + 30f, num * 1f, 132f), temperature, 50f, -20f);
|
|
GUI.TextArea(new Rect(2f * (num + 10f), 3f * num2, num * 2f, 20f), "Time of Day");
|
|
TOD = GUI.HorizontalSlider(new Rect(2f * (num + 10f), 3f * num2 + 25f, num * 2f, 20f), SUNMASTER.Current_Time, 0f, 24f);
|
|
SUNMASTER.Current_Time = TOD;
|
|
if (GUI.Button(new Rect(2f, 8f * num2, num - 2f, 22f), "Status"))
|
|
{
|
|
if (enableStratus)
|
|
{
|
|
enableStratus = false;
|
|
}
|
|
else
|
|
{
|
|
enableStratus = true;
|
|
enableCirrus = false;
|
|
enableCumulus = false;
|
|
}
|
|
}
|
|
if (GUI.Button(new Rect(2f, 9f * num2, num - 2f, 22f), "Cumulus"))
|
|
{
|
|
if (enableCumulus)
|
|
{
|
|
enableCumulus = false;
|
|
}
|
|
else
|
|
{
|
|
enableCumulus = true;
|
|
enableStratus = false;
|
|
enableCirrus = false;
|
|
}
|
|
}
|
|
if (GUI.Button(new Rect(2f, 10f * num2, num - 2f, 22f), "Cirrus"))
|
|
{
|
|
if (enableCirrus)
|
|
{
|
|
enableCirrus = false;
|
|
}
|
|
else
|
|
{
|
|
enableCirrus = true;
|
|
enableCumulus = false;
|
|
enableStratus = false;
|
|
}
|
|
}
|
|
if (changedWeather && Time.fixedTime - changedWeatherTime > weatherChangeDelay)
|
|
{
|
|
changedWeather = false;
|
|
}
|
|
if (enableStratus)
|
|
{
|
|
if (enable2DStratus)
|
|
{
|
|
volumeClouds1 = false;
|
|
SUNMASTER.volumeClouds.enabled = false;
|
|
SUNMASTER.volumeClouds.reflectClouds.enabled = false;
|
|
volumeClouds2 = false;
|
|
volumeClouds2SCRIPT.enabled = false;
|
|
WeatherPatternSCRIPT.gameObject.SetActive(value: false);
|
|
volumeClouds2SCRIPT_REFL.enabled = false;
|
|
SUNMASTER.VolShaderClouds.gameObject.SetActive(value: true);
|
|
_ = prevSky;
|
|
_ = 1;
|
|
if (VolCloud > 4)
|
|
{
|
|
VolCloud = 0;
|
|
}
|
|
if (VolCloud == 0)
|
|
{
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = true;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTERAH.ApplyType0Default(SUNMASTERAH);
|
|
}
|
|
if (VolCloud == 1)
|
|
{
|
|
CloudHandler.DomeClouds = true;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTERAH.ApplyType1Default(SUNMASTERAH);
|
|
}
|
|
if (VolCloud == 2)
|
|
{
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = true;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTERAH.ApplyType1Default(SUNMASTERAH);
|
|
}
|
|
if (VolCloud == 3)
|
|
{
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = true;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTERAH.ApplyType1Default(SUNMASTERAH);
|
|
}
|
|
if (VolCloud == 4)
|
|
{
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = true;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTERAH.ApplyType1Default(SUNMASTERAH);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
volumeClouds1 = true;
|
|
SUNMASTER.volumeClouds.enabled = true;
|
|
SUNMASTER.volumeClouds.reflectClouds.enabled = true;
|
|
SUNMASTER.volumeClouds._Altitude0 = 3300f;
|
|
SUNMASTER.volumeClouds._Altitude1 = 4500f;
|
|
SUNMASTER.volumeClouds.contrast = 11f;
|
|
SUNMASTER.volumeClouds._InteractTextureAtr.x = 0.9f;
|
|
SUNMASTER.volumeClouds._InteractTextureAtr.y = 0.999f;
|
|
SUNMASTER.volumeClouds._NoiseAmp1 = 5.3999996f + humidity * 0.01f;
|
|
volumeClouds2 = false;
|
|
volumeClouds2SCRIPT.enabled = false;
|
|
WeatherPatternSCRIPT.gameObject.SetActive(value: false);
|
|
volumeClouds2SCRIPT_REFL.enabled = false;
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTER.VolCloudGradients = false;
|
|
SUNMASTER.VolShaderClouds.gameObject.SetActive(value: false);
|
|
}
|
|
if (humidity > HighHumidity && temperature > highTemperature)
|
|
{
|
|
if (!changedWeather && SUNMASTER.currentWeatherName != SkyMasterManager.Volume_Weather_types.Rain)
|
|
{
|
|
SUNMASTER.currentWeatherName = SkyMasterManager.Volume_Weather_types.Rain;
|
|
changedWeather = true;
|
|
changedWeatherTime = Time.fixedTime;
|
|
Debug.Log("Changing weather to Rain");
|
|
}
|
|
SUNMASTER.WeatherSeverity = humidity - HighHumidity;
|
|
}
|
|
if (temperature < highTemperature)
|
|
{
|
|
if (!changedWeather && SUNMASTER.currentWeatherName != SkyMasterManager.Volume_Weather_types.SnowStorm)
|
|
{
|
|
SUNMASTER.currentWeatherName = SkyMasterManager.Volume_Weather_types.SnowStorm;
|
|
changedWeather = true;
|
|
changedWeatherTime = Time.fixedTime;
|
|
Debug.Log("Changing weather to SnowStorm");
|
|
}
|
|
SUNMASTER.WeatherSeverity = highTemperature - temperature;
|
|
}
|
|
if (humidity < HighHumidity && temperature > highTemperature)
|
|
{
|
|
if (!changedWeather && SUNMASTER.currentWeatherName != SkyMasterManager.Volume_Weather_types.Cloudy)
|
|
{
|
|
SUNMASTER.currentWeatherName = SkyMasterManager.Volume_Weather_types.Cloudy;
|
|
changedWeather = true;
|
|
changedWeatherTime = Time.fixedTime;
|
|
Debug.Log("Changing weather to Cloudy");
|
|
}
|
|
SUNMASTER.WeatherSeverity = 0f;
|
|
}
|
|
}
|
|
if (enableCumulus)
|
|
{
|
|
volumeClouds1 = false;
|
|
SUNMASTER.volumeClouds.enabled = false;
|
|
SUNMASTER.volumeClouds.reflectClouds.enabled = false;
|
|
volumeClouds2 = true;
|
|
volumeClouds2SCRIPT.enabled = true;
|
|
volumeClouds2SCRIPT_REFL.enabled = true;
|
|
WeatherPatternSCRIPT.gameObject.SetActive(value: true);
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTER.VolCloudGradients = false;
|
|
SUNMASTER.VolShaderClouds.gameObject.SetActive(value: false);
|
|
volumeClouds2SCRIPT.scale = 0.14f;
|
|
volumeClouds2SCRIPT.coverage = 0.55f + humidity * 0.008f;
|
|
volumeClouds2SCRIPT.coverageHigh = 0f;
|
|
if (temperature < highTemperature)
|
|
{
|
|
if (!changedWeather && SUNMASTER.currentWeatherName != SkyMasterManager.Volume_Weather_types.Rain)
|
|
{
|
|
SUNMASTER.currentWeatherName = SkyMasterManager.Volume_Weather_types.Rain;
|
|
changedWeather = true;
|
|
changedWeatherTime = Time.fixedTime;
|
|
Debug.Log("Changing weather to Heavy or Light Rain");
|
|
}
|
|
SUNMASTER.WeatherSeverity = humidity - HighHumidity;
|
|
}
|
|
else
|
|
{
|
|
if (!changedWeather && SUNMASTER.currentWeatherName != SkyMasterManager.Volume_Weather_types.Cloudy)
|
|
{
|
|
SUNMASTER.currentWeatherName = SkyMasterManager.Volume_Weather_types.Cloudy;
|
|
changedWeather = true;
|
|
changedWeatherTime = Time.fixedTime;
|
|
Debug.Log("Changing weather to Cloudy");
|
|
}
|
|
SUNMASTER.WeatherSeverity = 0f;
|
|
}
|
|
}
|
|
if (enableCirrus)
|
|
{
|
|
volumeClouds1 = false;
|
|
SUNMASTER.volumeClouds.enabled = false;
|
|
SUNMASTER.volumeClouds.reflectClouds.enabled = false;
|
|
volumeClouds2 = true;
|
|
volumeClouds2SCRIPT.enabled = true;
|
|
volumeClouds2SCRIPT_REFL.enabled = true;
|
|
WeatherPatternSCRIPT.gameObject.SetActive(value: true);
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTER.VolCloudGradients = false;
|
|
SUNMASTER.VolShaderClouds.gameObject.SetActive(value: false);
|
|
volumeClouds2SCRIPT.coverage = 0f;
|
|
volumeClouds2SCRIPT.coverageHigh = 3f * (humidity / 100f);
|
|
volumeClouds2SCRIPT.highCloudsScale = 0.008f;
|
|
if (!changedWeather && SUNMASTER.currentWeatherName != SkyMasterManager.Volume_Weather_types.Cloudy)
|
|
{
|
|
SUNMASTER.currentWeatherName = SkyMasterManager.Volume_Weather_types.Cloudy;
|
|
changedWeather = true;
|
|
changedWeatherTime = Time.fixedTime;
|
|
Debug.Log("Changing weather to Cloudy");
|
|
}
|
|
SUNMASTER.WeatherSeverity = 0f;
|
|
}
|
|
return;
|
|
}
|
|
string text = "Disable HUD";
|
|
if (!HUD_ON)
|
|
{
|
|
text = "Enable HUD";
|
|
}
|
|
if (GUI.Button(new Rect(2f, 0f * num2, num - 2f, 22f), text))
|
|
{
|
|
if (HUD_ON)
|
|
{
|
|
HUD_ON = false;
|
|
}
|
|
else
|
|
{
|
|
HUD_ON = true;
|
|
}
|
|
}
|
|
float num3 = 5f;
|
|
if (!HUD_ON)
|
|
{
|
|
return;
|
|
}
|
|
GUI.TextArea(new Rect(3f * num + 10f, num2 + 60f + 30f + 31f + 31f + 31f + 31f + 31f + 11f, num * 2f, 22f), "Weather intensity:" + SUNMASTER.WeatherSeverity);
|
|
SUNMASTER.WeatherSeverity = GUI.HorizontalSlider(new Rect(3f * num + 10f, num2 + 60f + 30f + 31f + 31f + 31f + 31f + 31f + 31f + 11f, num * 4f, 32f), SUNMASTER.WeatherSeverity, 1f, 20f);
|
|
GUI.TextArea(new Rect(6f * num + 20f + 10f, num2 + 60f + 30f + 30f + 0f - 2f, num + 10f, 21f), "Sky brightness");
|
|
SUNMASTER.SkyColorationOffset = GUI.HorizontalSlider(new Rect(6f * num + 20f + 10f, num2 + 60f + 30f + 0f + 60f - 5f - 3f, num + 10f, 30f), SUNMASTER.SkyColorationOffset, -0.4f, 0.5f);
|
|
GUI.TextArea(new Rect(7f * num + 35f + 10f, num2 + 60f + 30f + 30f + 0f - 2f, num + 10f, 21f), "Cloud brightness");
|
|
SUNMASTER.VolShaderCloudsH.IntensityDiffOffset = GUI.HorizontalSlider(new Rect(7f * num + 35f + 10f, num2 + 60f + 30f + 0f + 60f - 5f - 3f, num + 10f, 30f), SUNMASTER.VolShaderCloudsH.IntensityDiffOffset, -0.35f, 0.35f);
|
|
GUI.TextArea(new Rect(8f * num + 35f + 25f, num2 + 60f + 30f + 30f + 0f - 2f, num + 15f, 21f), "Horizon brightness");
|
|
SUNMASTER.FogColorPow = GUI.HorizontalSlider(new Rect(8f * num + 35f + 25f, num2 + 60f + 30f + 0f + 60f - 5f - 3f, num + 15f, 30f), SUNMASTER.FogColorPow, -5f, 5f);
|
|
GUI.TextArea(new Rect(5f * num + 20f, num2 + 60f + 30f + 0f + 0f - 12f, num, 21f), "Cloud Horizon");
|
|
SUNMASTER.VolShaderCloudsH.ClearDayHorizon = GUI.HorizontalSlider(new Rect(5f * num + 20f, num2 + 60f + 0f + 0f + 60f - 5f - 13f, num, 30f), SUNMASTER.VolShaderCloudsH.ClearDayHorizon, 0f, 0.4f);
|
|
string text2 = "on";
|
|
if (Freezeme)
|
|
{
|
|
text2 = "off";
|
|
}
|
|
if (GUI.Button(new Rect(4f * num + 10f, num2 + 60f + 30f + 0f, num, 30f), "Freeze " + text2))
|
|
{
|
|
if (Freezeme)
|
|
{
|
|
Freezeme = false;
|
|
SUNMASTER.MaxWater = 0.4f;
|
|
SUNMASTER.MaxRefract = 0f;
|
|
}
|
|
else
|
|
{
|
|
Freezeme = true;
|
|
SUNMASTER.MaxWater = 0.4f;
|
|
SUNMASTER.MaxRefract = 5f;
|
|
}
|
|
}
|
|
if (Freezeme)
|
|
{
|
|
SUNMASTER.FreezeInwards = true;
|
|
SUNMASTER.ScreenFreezeFX = true;
|
|
SUNMASTER.FreezeSpeed = 2f;
|
|
GUI.TextArea(new Rect(4f * num + 10f, num2 + 60f + 30f + 30f + 0f - 2f, num, 21f), "Freeze Amount");
|
|
SUNMASTER.MaxRefract = GUI.HorizontalSlider(new Rect(4f * num + 10f, num2 + 60f + 30f + 0f + 60f - 5f - 3f, num, 30f), SUNMASTER.MaxRefract, 0f, 210f);
|
|
}
|
|
else
|
|
{
|
|
SUNMASTER.ScreenFreezeFX = false;
|
|
SUNMASTER.FreezeSpeed = 2f;
|
|
SUNMASTER.MaxRefract = 0f;
|
|
}
|
|
if (Time.fixedTime - last_bomb_time > 8f && GUI.Button(new Rect(3f * num + 10f, num2 + 60f + 30f, num, 30f), "Cast ABomb"))
|
|
{
|
|
Object.Instantiate(Abomb, Camera.main.transform.position + Camera.main.transform.forward * 100f, Quaternion.identity).SetActive(value: true);
|
|
last_bomb_time = Time.fixedTime;
|
|
}
|
|
if (GUI.Button(new Rect(3f * num + 10f, num2 + 60f + 30f + 31f, num, 22f), "Toggle Volcano"))
|
|
{
|
|
if (!Volcano.activeInHierarchy)
|
|
{
|
|
Volcano.SetActive(value: true);
|
|
}
|
|
else
|
|
{
|
|
Volcano.SetActive(value: false);
|
|
}
|
|
}
|
|
if (activeSky == 1)
|
|
{
|
|
string text3 = "On";
|
|
if (Special_effects)
|
|
{
|
|
text3 = "Off";
|
|
}
|
|
if (GUI.Button(new Rect(3f * num + 10f, num2 + 60f + 30f + 30f, num, 30f), "Special FX " + text3))
|
|
{
|
|
if (Special_effects)
|
|
{
|
|
Special_effects = false;
|
|
}
|
|
else
|
|
{
|
|
Special_effects = true;
|
|
}
|
|
}
|
|
if (Special_effects)
|
|
{
|
|
string text4 = "On";
|
|
if (Rain2_on)
|
|
{
|
|
text4 = "Off";
|
|
}
|
|
if (GUI.Button(new Rect(25f + 3f * num + 10f, num2 + 60f + 30f + 40f + 30f, num, 20f), "Heavy Rain " + text4))
|
|
{
|
|
if (Rain2_on)
|
|
{
|
|
Rain2_on = false;
|
|
if (Rain2.activeInHierarchy)
|
|
{
|
|
Rain2.SetActive(value: false);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
Rain2_on = true;
|
|
Disable_all();
|
|
if (!Rain2.activeInHierarchy)
|
|
{
|
|
Rain2.SetActive(value: true);
|
|
}
|
|
}
|
|
}
|
|
string text5 = "On";
|
|
if (Leaves_on)
|
|
{
|
|
text5 = "Off";
|
|
}
|
|
if (GUI.Button(new Rect(25f + 3f * num + 10f, num2 + 60f + 30f + 60f + 30f, num, 20f), "Leaves " + text5))
|
|
{
|
|
if (Leaves_on)
|
|
{
|
|
Leaves_on = false;
|
|
if (Leaves.activeInHierarchy)
|
|
{
|
|
Leaves.SetActive(value: false);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
Leaves_on = true;
|
|
Disable_all();
|
|
if (!Leaves.activeInHierarchy)
|
|
{
|
|
Leaves.SetActive(value: true);
|
|
}
|
|
}
|
|
}
|
|
string text6 = "On";
|
|
if (Bats_on)
|
|
{
|
|
text6 = "Off";
|
|
}
|
|
if (GUI.Button(new Rect(25f + 3f * num + 10f, num2 + 60f + 30f + 80f + 30f, num, 20f), "Bats " + text6))
|
|
{
|
|
if (Bats_on)
|
|
{
|
|
Bats_on = false;
|
|
if (Bats.activeInHierarchy)
|
|
{
|
|
Bats.SetActive(value: false);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
if (Floor.activeInHierarchy)
|
|
{
|
|
Floor.SetActive(value: false);
|
|
}
|
|
if (Floor_stripes.activeInHierarchy)
|
|
{
|
|
Floor_stripes.SetActive(value: false);
|
|
}
|
|
if (Floor_collider.activeInHierarchy)
|
|
{
|
|
Floor_collider.SetActive(value: false);
|
|
}
|
|
Bats_on = true;
|
|
Disable_all();
|
|
if (!Bats.activeInHierarchy)
|
|
{
|
|
Bats.SetActive(value: true);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (Special_effects)
|
|
{
|
|
if (!Bats.activeInHierarchy)
|
|
{
|
|
if (!Floor.activeInHierarchy)
|
|
{
|
|
Floor.SetActive(value: true);
|
|
}
|
|
if (!Floor_stripes.activeInHierarchy)
|
|
{
|
|
Floor_stripes.SetActive(value: true);
|
|
}
|
|
if (!Floor_collider.activeInHierarchy)
|
|
{
|
|
Floor_collider.SetActive(value: true);
|
|
}
|
|
}
|
|
}
|
|
else
|
|
{
|
|
if (Floor.activeInHierarchy)
|
|
{
|
|
Floor.SetActive(value: false);
|
|
}
|
|
if (Floor_stripes.activeInHierarchy)
|
|
{
|
|
Floor_stripes.SetActive(value: false);
|
|
}
|
|
if (Leaves.activeInHierarchy)
|
|
{
|
|
Leaves.SetActive(value: false);
|
|
}
|
|
if (Bats.activeInHierarchy)
|
|
{
|
|
Bats.SetActive(value: false);
|
|
}
|
|
if (Rain2.activeInHierarchy)
|
|
{
|
|
Rain2.SetActive(value: false);
|
|
}
|
|
if (Floor_collider.activeInHierarchy)
|
|
{
|
|
Floor_collider.SetActive(value: false);
|
|
}
|
|
}
|
|
}
|
|
GUI.TextArea(new Rect(2f, 13f * num2 + 4f, num - 2f + 0f, 22f), "Shadow Dist.");
|
|
QualitySettings.shadowDistance = GUI.HorizontalSlider(new Rect(2f, 14f * num2, num - 2f + 0f, 22f), QualitySettings.shadowDistance, 250f, 3500f);
|
|
string text7 = "on";
|
|
if (!SUNMASTERAH.Use_fog)
|
|
{
|
|
text7 = "off";
|
|
}
|
|
if (GUI.Button(new Rect(2f, 14f * num2 + 15f, num - 2f + 2f, 22f), "Unity fog " + text7))
|
|
{
|
|
if (SUNMASTERAH.Use_fog)
|
|
{
|
|
SUNMASTERAH.Use_fog = false;
|
|
}
|
|
else
|
|
{
|
|
SUNMASTERAH.Use_fog = true;
|
|
}
|
|
}
|
|
if (CinemaLook)
|
|
{
|
|
GUI.TextArea(new Rect(2f, 15f * num2 + 10f, num - 2f + 0f, 22f), "Caustic Bright.");
|
|
WaterHandler.CausticIntensity = GUI.HorizontalSlider(new Rect(2f, 16f * num2 + 10f, num - 2f + 0f, 22f), WaterHandler.CausticIntensity, 0f, 30f);
|
|
}
|
|
string text8 = "Full Reflect";
|
|
if (limitRef == 0)
|
|
{
|
|
text8 = "Full Reflect";
|
|
}
|
|
if (limitRef == 1)
|
|
{
|
|
text8 = "Optimized Reflect";
|
|
}
|
|
if (limitRef == 2)
|
|
{
|
|
text8 = "No Reflections";
|
|
}
|
|
GUI.TextArea(new Rect(2f, 12f * num2, num - 2f + 2f, 22f), text8);
|
|
if (GUI.Button(new Rect(2f, 11f * num2, num - 2f + 2f, 22f), "Reflect Quality"))
|
|
{
|
|
if (limitRef == 0)
|
|
{
|
|
SUNMASTERA.GetComponent<SkyMasterManager>().water.gameObject.GetComponent<PlanarReflectionSM>().reflectionMask = 1 << LayerMask.NameToLayer("TerrainSM");
|
|
SUNMASTERB.GetComponent<SkyMasterManager>().water.gameObject.GetComponent<PlanarReflectionSM>().reflectionMask = 1 << LayerMask.NameToLayer("TerrainSM");
|
|
SUNMASTERA.GetComponent<SkyMasterManager>().SkyboxLayer = (1 << LayerMask.NameToLayer("TerrainSM")) | (1 << LayerMask.NameToLayer("Water"));
|
|
SUNMASTERB.GetComponent<SkyMasterManager>().SkyboxLayer = (1 << LayerMask.NameToLayer("TerrainSM")) | (1 << LayerMask.NameToLayer("Water"));
|
|
}
|
|
else if (limitRef == 1)
|
|
{
|
|
SUNMASTERA.GetComponent<SkyMasterManager>().water.gameObject.GetComponent<PlanarReflectionSM>().reflectionMask = 0;
|
|
SUNMASTERB.GetComponent<SkyMasterManager>().water.gameObject.GetComponent<PlanarReflectionSM>().reflectionMask = 0;
|
|
SUNMASTERA.GetComponent<SkyMasterManager>().SkyboxLayer = 0;
|
|
SUNMASTERB.GetComponent<SkyMasterManager>().SkyboxLayer = 0;
|
|
}
|
|
else if (limitRef == 2)
|
|
{
|
|
SUNMASTERA.GetComponent<SkyMasterManager>().water.gameObject.GetComponent<PlanarReflectionSM>().reflectionMask = -1;
|
|
SUNMASTERB.GetComponent<SkyMasterManager>().water.gameObject.GetComponent<PlanarReflectionSM>().reflectionMask = -1;
|
|
SUNMASTERA.GetComponent<SkyMasterManager>().SkyboxLayer = -1;
|
|
SUNMASTERB.GetComponent<SkyMasterManager>().SkyboxLayer = -1;
|
|
}
|
|
limitRef++;
|
|
if (limitRef > 2)
|
|
{
|
|
limitRef = 0;
|
|
}
|
|
}
|
|
string text9 = "off";
|
|
if (CinemaLook)
|
|
{
|
|
text9 = "on";
|
|
}
|
|
if (GUI.Button(new Rect(2f, 10f * num2, num - 2f, 22f), "Cinematics " + text9))
|
|
{
|
|
if (CinemaLook)
|
|
{
|
|
Camera1.GetComponentsInChildren<UnderWaterImageEffect>()[^1].enabled = false;
|
|
Camera2.GetComponentsInChildren<UnderWaterImageEffect>()[^1].enabled = false;
|
|
if (!PointLights.gameObject.activeInHierarchy)
|
|
{
|
|
PointLights.gameObject.SetActive(value: true);
|
|
}
|
|
if (PointLightsCin.gameObject.activeInHierarchy)
|
|
{
|
|
PointLightsCin.gameObject.SetActive(value: false);
|
|
}
|
|
SUNMASTERA.GetComponent<SkyMasterManager>().SUN_LIGHT.GetComponent<Light>().flare = null;
|
|
SUNMASTERB.GetComponent<SkyMasterManager>().SUN_LIGHT.GetComponent<Light>().flare = null;
|
|
CinemaLook = false;
|
|
Caustics.SetActive(value: false);
|
|
}
|
|
else
|
|
{
|
|
Camera1.GetComponentsInChildren<UnderWaterImageEffect>()[^1].enabled = true;
|
|
Camera2.GetComponentsInChildren<UnderWaterImageEffect>()[^1].enabled = true;
|
|
if (PointLights.gameObject.activeInHierarchy)
|
|
{
|
|
PointLights.gameObject.SetActive(value: false);
|
|
}
|
|
if (!PointLightsCin.gameObject.activeInHierarchy)
|
|
{
|
|
PointLightsCin.gameObject.SetActive(value: true);
|
|
}
|
|
SUNMASTERA.GetComponent<SkyMasterManager>().SUN_LIGHT.GetComponent<Light>().flare = FlareTexture;
|
|
SUNMASTERB.GetComponent<SkyMasterManager>().SUN_LIGHT.GetComponent<Light>().flare = FlareTexture;
|
|
CinemaLook = true;
|
|
Caustics.SetActive(value: true);
|
|
}
|
|
}
|
|
if (GUI.Button(new Rect(2f, 5f * num2, num - 2f, 22f), "Toggle sky"))
|
|
{
|
|
if (activeSky == 0)
|
|
{
|
|
if (Camera.main != null)
|
|
{
|
|
Camera.main.transform.parent = AtollViewSpot;
|
|
Camera.main.transform.localPosition = new Vector3(0f, 0f, 0f);
|
|
Camera.main.transform.parent = skyA.transform;
|
|
Camera.main.transform.up = Vector3.up;
|
|
}
|
|
skyB.SetActive(value: true);
|
|
skyA.SetActive(value: false);
|
|
SUNMASTER = SUNMASTERB.GetComponent<SkyMasterManager>();
|
|
activeSky = 1;
|
|
SUNMASTER.water.GetComponent<GerstnerDisplaceSM>().enabled = false;
|
|
SUNMASTER.water.GetComponent<GerstnerDisplaceSM>().enabled = true;
|
|
SUNMASTER.VolLightingH.SkyManager = SUNMASTER;
|
|
}
|
|
else
|
|
{
|
|
if (Camera.main != null)
|
|
{
|
|
Camera.main.transform.parent = AtollViewSpot;
|
|
Camera.main.transform.localPosition = new Vector3(0f, 0f, 0f);
|
|
Camera.main.transform.parent = skyB.transform;
|
|
Camera.main.transform.up = Vector3.up;
|
|
}
|
|
skyA.SetActive(value: true);
|
|
skyB.SetActive(value: false);
|
|
SUNMASTER = SUNMASTERA.GetComponent<SkyMasterManager>();
|
|
activeSky = 0;
|
|
SUNMASTER.water.GetComponent<GerstnerDisplaceSM>().enabled = false;
|
|
SUNMASTER.water.GetComponent<GerstnerDisplaceSM>().enabled = true;
|
|
SUNMASTER.VolLightingH.SkyManager = SUNMASTER;
|
|
}
|
|
prevSky = 1;
|
|
}
|
|
if (activeSky == 1)
|
|
{
|
|
if (Fog == null)
|
|
{
|
|
Fog = Camera.main.GetComponent<GlobalFogSkyMaster>();
|
|
}
|
|
if (Fog != null)
|
|
{
|
|
RaycastHit hitInfo = default(RaycastHit);
|
|
Vector3 direction = Camera.main.transform.position - SUNMASTER.SunObj.transform.position;
|
|
if (Physics.Raycast(SUNMASTER.SunObj.transform.position, direction, out hitInfo, direction.magnitude))
|
|
{
|
|
Fog.mieDirectionalG = 0.833f;
|
|
Fog.contrast = 2.5f;
|
|
}
|
|
else
|
|
{
|
|
Fog.mieDirectionalG = 0.913f;
|
|
Fog.contrast = 1.51f;
|
|
}
|
|
}
|
|
}
|
|
GUI.TextArea(new Rect(2f, 1f * num2, 98f, 20f), "Sun Speed");
|
|
SPEED = GUI.HorizontalSlider(new Rect(2f, 1f * num2 + 25f, 98f, 30f), SPEED, 0.01f, 70f);
|
|
SUNMASTER.SPEED = SPEED;
|
|
GUI.TextArea(new Rect(2f, 1f * num2 + 50f, 98f, 20f), "Sun Intensity");
|
|
SUNMASTER.Max_sun_intensity = GUI.HorizontalSlider(new Rect(2f, 1f * num2 + 25f + 50f, 98f, 15f), SUNMASTER.Max_sun_intensity, 0.5f, 2.5f);
|
|
GUI.TextArea(new Rect(2f, 4f * num2 + 50f + 10f, 98f, 20f), "Sun Beams");
|
|
SUNMASTER.VolLightingH.heightRayleighIntensity = GUI.HorizontalSlider(new Rect(2f, 4f * num2 + 25f + 50f + 10f, 98f, 15f), SUNMASTER.VolLightingH.heightRayleighIntensity, 0f, 0.7f);
|
|
GUI.TextArea(new Rect(2f, 5f * num2 + 70f + 10f, 98f, 20f), "Ambient");
|
|
SUNMASTER.AmbientIntensity = GUI.HorizontalSlider(new Rect(2f, 5f * num2 + 25f + 70f + 10f, 98f, 15f), SUNMASTER.AmbientIntensity, 0f, 1.8f);
|
|
if ((windowsON == 0) | (windowsON == 3))
|
|
{
|
|
GUI.TextArea(new Rect(6f * (num + num3), 1f * num2 + 25f, num + 0f, 20f), "Camera height");
|
|
Camera_up = GUI.HorizontalSlider(new Rect(6f * (num + num3), 1f * num2 + 25f + 25f, num + 315f, 30f), Camera.main.transform.position.y, min_height, 1760f);
|
|
Camera.main.transform.position = new Vector3(Camera.main.transform.position.x, Camera_up, Camera.main.transform.position.z);
|
|
}
|
|
GUI.TextArea(new Rect(6f * (num + num3), 3f * num2 + 10f, num + 0f, 20f), "Cloud coverage");
|
|
if (!volumeClouds1 && !volumeClouds2)
|
|
{
|
|
if (CloudHandler.DomeClouds)
|
|
{
|
|
SUNMASTER.VolShaderCloudsH.ClearDayCoverage = GUI.HorizontalSlider(new Rect(6f * (num + num3), 3f * num2 + 25f + 10f, num * 4f + 15f, 30f), SUNMASTER.VolShaderCloudsH.ClearDayCoverage, -8.6f, 1.4f);
|
|
}
|
|
if (CloudHandler.MultiQuadClouds)
|
|
{
|
|
SUNMASTER.VolShaderCloudsH.ClearDayCoverage = GUI.HorizontalSlider(new Rect(6f * (num + num3), 3f * num2 + 25f + 10f, num * 4f + 15f, 30f), SUNMASTER.VolShaderCloudsH.ClearDayCoverage, -0.55f, -0.05f);
|
|
}
|
|
if (CloudHandler.MultiQuadAClouds)
|
|
{
|
|
SUNMASTER.VolShaderCloudsH.ClearDayCoverage = GUI.HorizontalSlider(new Rect(6f * (num + num3), 3f * num2 + 25f + 10f, num * 4f + 15f, 30f), SUNMASTER.VolShaderCloudsH.ClearDayCoverage, -0.55f, -0.05f);
|
|
}
|
|
if (CloudHandler.OneQuadClouds)
|
|
{
|
|
SUNMASTER.VolShaderCloudsH.ClearDayCoverage = GUI.HorizontalSlider(new Rect(6f * (num + num3), 3f * num2 + 25f + 10f, num * 4f + 15f, 30f), SUNMASTER.VolShaderCloudsH.ClearDayCoverage, -1.25f, 1.05f);
|
|
}
|
|
if (CloudHandler.MultiQuadBClouds)
|
|
{
|
|
SUNMASTER.VolShaderCloudsH.ClearDayCoverage = GUI.HorizontalSlider(new Rect(6f * (num + num3), 3f * num2 + 25f + 10f, num * 4f + 15f, 30f), SUNMASTER.VolShaderCloudsH.ClearDayCoverage, -0.55f, -0.05f);
|
|
}
|
|
if (CloudHandler.MultiQuadCClouds)
|
|
{
|
|
SUNMASTER.VolShaderCloudsH.ClearDayCoverage = GUI.HorizontalSlider(new Rect(6f * (num + num3), 3f * num2 + 25f + 10f, num * 4f + 15f, 30f), SUNMASTER.VolShaderCloudsH.ClearDayCoverage, -15.55f, 5f);
|
|
}
|
|
}
|
|
else
|
|
{
|
|
if (volumeClouds1 && SUNMASTER.volumeClouds != null)
|
|
{
|
|
SUNMASTER.volumeClouds._NoiseAmp1 = GUI.HorizontalSlider(new Rect(6f * (num + num3), 3f * num2 + 25f + 10f, num * 4f + 15f, 30f), SUNMASTER.volumeClouds._NoiseAmp1, 1.55f, 15f);
|
|
}
|
|
if (volumeClouds2 && volumeClouds2SCRIPT != null)
|
|
{
|
|
volumeClouds2SCRIPT.coverage = GUI.HorizontalSlider(new Rect(6f * (num + num3), 3f * num2 + 25f + 10f, num * 4f + 15f, 30f), volumeClouds2SCRIPT.coverage, 0f, 1.6f);
|
|
volumeClouds2SCRIPT_REFL.coverage = volumeClouds2SCRIPT.coverage;
|
|
}
|
|
}
|
|
if (Camera_up > 200f)
|
|
{
|
|
if (farOceanplane.activeInHierarchy)
|
|
{
|
|
farOceanplane.SetActive(value: false);
|
|
}
|
|
}
|
|
else if (!farOceanplane.activeInHierarchy)
|
|
{
|
|
farOceanplane.SetActive(value: true);
|
|
}
|
|
GUI.TextArea(new Rect(2f * (num + num3), 1f * num2, num + 0f, 20f), "SkyDome rot");
|
|
Dome_rot = GUI.HorizontalSlider(new Rect(2f * (num + num3), 1f * num2 + 25f, num + 0f, 30f), Dome_rot, 0f, 360f);
|
|
SUNMASTER.Rot_Sun_Y = Dome_rot;
|
|
GUI.TextArea(new Rect(3f * (num + num3), 1f * num2, num + 0f, 20f), "Wind direction");
|
|
float y = GUI.HorizontalSlider(new Rect(3f * (num + num3), 1f * num2 + 25f, num + 0f, 30f), SUNMASTER.windZone.transform.eulerAngles.y, 0f, 360f);
|
|
Vector3 eulerAngles = SUNMASTER.windZone.gameObject.transform.eulerAngles;
|
|
SUNMASTER.windZone.gameObject.transform.eulerAngles = new Vector3(eulerAngles.x, y, eulerAngles.z);
|
|
GUI.TextArea(new Rect(4f * (num + num3), 1f * num2, num + 0f, 20f), "Wind intensity");
|
|
SUNMASTER.windZone.windMain = GUI.HorizontalSlider(new Rect(4f * (num + num3), 1f * num2 + 25f, num + 0f, 30f), SUNMASTER.windZone.windMain, 0f, 24f);
|
|
if (activeSky == 0)
|
|
{
|
|
GUI.TextArea(new Rect(1f * (num + num3), 1f * num2, num, 20f), "Time of Day");
|
|
TOD = GUI.HorizontalSlider(new Rect(1f * (num + num3), 1f * num2 + 25f, num, 20f), SUNMASTER.Current_Time, 0f, 24f);
|
|
SUNMASTER.Current_Time = TOD;
|
|
}
|
|
if (activeSky == 1)
|
|
{
|
|
GUI.TextArea(new Rect(1f * (num + num3), 1f * num2, num, 20f), "Time of Day");
|
|
TOD = GUI.HorizontalSlider(new Rect(1f * (num + num3), 1f * num2 + 25f, num, 20f), SUNMASTER.Current_Time, 9.4f, 12f);
|
|
SUNMASTER.Current_Time = TOD;
|
|
}
|
|
if (activeSky == 0 && GUI.Button(new Rect(2f * (num + num3), 1f * num2 + 50f, num * 2f, 20f), "Toggle Refect Probe"))
|
|
{
|
|
if (SUNMASTER.USE_SKYCUBE)
|
|
{
|
|
SUNMASTER.USE_SKYCUBE = false;
|
|
}
|
|
else
|
|
{
|
|
SUNMASTER.USE_SKYCUBE = true;
|
|
}
|
|
}
|
|
if (GUI.Button(new Rect(4f * (num + num3), 1f * num2 + 50f, num * 2f, 20f), "Toggle Tiny Planet"))
|
|
{
|
|
if (!TinyPlanet.gameObject.activeInHierarchy)
|
|
{
|
|
TinyPlanet.gameObject.SetActive(value: true);
|
|
}
|
|
else
|
|
{
|
|
TinyPlanet.gameObject.SetActive(value: false);
|
|
}
|
|
}
|
|
if (VolCloud == 0 && GUI.Button(new Rect(2f * (num + num3), 2f * num2 + 20f + 21f, num * 2f, 20f), "Toggle Light Scatter"))
|
|
{
|
|
if (CloudHandler.MultiQuadClouds)
|
|
{
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = true;
|
|
SUNMASTERAH.ApplyType0Scatter(SUNMASTERAH);
|
|
}
|
|
else
|
|
{
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = true;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTERAH.ApplyType0Default(SUNMASTERAH);
|
|
}
|
|
}
|
|
if (EnablecloudPresets)
|
|
{
|
|
if (GUI.Button(new Rect(1f * (num + num3), 1f * num2 + 50f + 20f, num, 20f), "Presets"))
|
|
{
|
|
if (!cloudPresets)
|
|
{
|
|
cloudPresets = true;
|
|
}
|
|
else
|
|
{
|
|
cloudPresets = false;
|
|
}
|
|
}
|
|
if (cloudPresets)
|
|
{
|
|
if (VolCloud == 0 && CloudHandler.MultiQuadClouds)
|
|
{
|
|
if (GUI.Button(new Rect(1f * (num + num3), 1f * num2 + 50f + 20f + 20f, num * 2f + 5f, 75f), cloudsAPic0))
|
|
{
|
|
SUNMASTERAH.ApplyType0Default(SUNMASTERAH);
|
|
}
|
|
if (GUI.Button(new Rect(1f * (num + num3), 1f * num2 + 50f + 20f + 20f + 75f, num * 2f + 5f, 75f), cloudsAPic1))
|
|
{
|
|
SUNMASTERAH.ApplyType0Default1(SUNMASTERAH);
|
|
}
|
|
if (GUI.Button(new Rect(1f * (num + num3), 1f * num2 + 50f + 20f + 20f + 150f, num * 2f + 5f, 75f), cloudsAPic2))
|
|
{
|
|
SUNMASTERAH.ApplyType0Default2(SUNMASTERAH);
|
|
}
|
|
if (GUI.Button(new Rect(1f * (num + num3), 1f * num2 + 50f + 20f + 20f + 225f, num * 2f + 5f, 75f), cloudsAPic3))
|
|
{
|
|
SUNMASTERAH.ApplyType0Default3(SUNMASTERAH);
|
|
}
|
|
if (GUI.Button(new Rect(1f * (num + num3), 1f * num2 + 50f + 20f + 20f + 300f, num * 2f + 5f, 75f), cloudsAPic4))
|
|
{
|
|
SUNMASTERAH.ApplyType0Default4(SUNMASTERAH);
|
|
}
|
|
}
|
|
if (VolCloud == 1)
|
|
{
|
|
if (GUI.Button(new Rect(1f * (num + num3), 1f * num2 + 50f + 20f + 20f, num * 2f + 5f, 75f), cloudsBPic0))
|
|
{
|
|
SUNMASTERAH.ApplyType1Default(SUNMASTERAH);
|
|
}
|
|
if (GUI.Button(new Rect(1f * (num + num3), 1f * num2 + 50f + 20f + 20f + 75f, num * 2f + 5f, 75f), cloudsBPic1))
|
|
{
|
|
SUNMASTERAH.ApplyType1Default1(SUNMASTERAH);
|
|
}
|
|
if (GUI.Button(new Rect(1f * (num + num3), 1f * num2 + 50f + 20f + 20f + 150f, num * 2f + 5f, 75f), cloudsBPic2))
|
|
{
|
|
SUNMASTERAH.ApplyType1Default2(SUNMASTERAH);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (GUI.Button(new Rect(3f * num + 10f, num2 + 60f + 30f + 31f + 31f, num * 2f, 32f), "Toggle Volume Clouds"))
|
|
{
|
|
volumeClouds1 = true;
|
|
SUNMASTER.volumeClouds.enabled = true;
|
|
SUNMASTER.volumeClouds.reflectClouds.enabled = true;
|
|
volumeClouds2 = false;
|
|
volumeClouds2SCRIPT.enabled = false;
|
|
WeatherPatternSCRIPT.gameObject.SetActive(value: false);
|
|
volumeClouds2SCRIPT_REFL.enabled = false;
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTER.VolCloudGradients = false;
|
|
SUNMASTER.VolShaderClouds.gameObject.SetActive(value: false);
|
|
}
|
|
if (GUI.Button(new Rect(3f * num + 10f, num2 + 60f + 30f + 31f + 31f + 31f, num * 2f, 32f), "Toggle Fly Through Clouds"))
|
|
{
|
|
volumeClouds1 = false;
|
|
SUNMASTER.volumeClouds.enabled = false;
|
|
SUNMASTER.volumeClouds.reflectClouds.enabled = false;
|
|
volumeClouds2 = true;
|
|
volumeClouds2SCRIPT.enabled = true;
|
|
volumeClouds2SCRIPT_REFL.enabled = true;
|
|
WeatherPatternSCRIPT.gameObject.SetActive(value: true);
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTER.VolCloudGradients = false;
|
|
SUNMASTER.VolShaderClouds.gameObject.SetActive(value: false);
|
|
}
|
|
if (GUI.Button(new Rect(1f * (num + num3), 1f * num2 + 50f, num, 20f), "Toggle Clouds") || prevSky == 1)
|
|
{
|
|
volumeClouds1 = false;
|
|
SUNMASTER.volumeClouds.enabled = false;
|
|
SUNMASTER.volumeClouds.reflectClouds.enabled = false;
|
|
volumeClouds2 = false;
|
|
volumeClouds2SCRIPT.enabled = false;
|
|
WeatherPatternSCRIPT.gameObject.SetActive(value: false);
|
|
volumeClouds2SCRIPT_REFL.enabled = false;
|
|
SUNMASTER.VolShaderClouds.gameObject.SetActive(value: true);
|
|
if (prevSky == 1)
|
|
{
|
|
prevSky = 0;
|
|
}
|
|
else
|
|
{
|
|
VolCloud++;
|
|
}
|
|
if (VolCloud > 4)
|
|
{
|
|
VolCloud = 0;
|
|
}
|
|
if (VolCloud == 0)
|
|
{
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = true;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTERAH.ApplyType0Default(SUNMASTERAH);
|
|
}
|
|
if (VolCloud == 1)
|
|
{
|
|
CloudHandler.DomeClouds = true;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTERAH.ApplyType1Default(SUNMASTERAH);
|
|
}
|
|
if (VolCloud == 2)
|
|
{
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = true;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTERAH.ApplyType1Default(SUNMASTERAH);
|
|
}
|
|
if (VolCloud == 3)
|
|
{
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = true;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTERAH.ApplyType1Default(SUNMASTERAH);
|
|
}
|
|
if (VolCloud == 4)
|
|
{
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = true;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTERAH.ApplyType1Default(SUNMASTERAH);
|
|
}
|
|
if (VolCloud == 5)
|
|
{
|
|
CloudHandler.DomeClouds = false;
|
|
CloudHandler.MultiQuadClouds = false;
|
|
CloudHandler.OneQuadClouds = false;
|
|
CloudHandler.MultiQuadAClouds = false;
|
|
CloudHandler.MultiQuadBClouds = false;
|
|
CloudHandler.MultiQuadCClouds = false;
|
|
SUNMASTER.VolCloudGradients = false;
|
|
if (activeSky == 0)
|
|
{
|
|
if (!made_once)
|
|
{
|
|
ParticleCloudsA.SetActive(value: true);
|
|
ParticleSystem component = ParticleCloudsA.GetComponent<ParticleSystem>();
|
|
if (component != null)
|
|
{
|
|
ParticleSystem.EmissionModule emission = component.emission;
|
|
emission.enabled = true;
|
|
}
|
|
ParticleCloudsA.GetComponent<VolumeClouds_SM>().enabled = true;
|
|
ParticleSystem component2 = ParticleCloudsB.GetComponent<ParticleSystem>();
|
|
if (component2 != null)
|
|
{
|
|
ParticleSystem.EmissionModule emission2 = component2.emission;
|
|
emission2.enabled = false;
|
|
}
|
|
ParticleCloudsB.GetComponent<VolumeClouds_SM>().enabled = false;
|
|
made_once = true;
|
|
}
|
|
else
|
|
{
|
|
ParticleSystem component3 = ParticleCloudsA.GetComponent<ParticleSystem>();
|
|
if (component3 != null)
|
|
{
|
|
ParticleSystem.EmissionModule emission3 = component3.emission;
|
|
emission3.enabled = true;
|
|
}
|
|
ParticleCloudsA.GetComponent<VolumeClouds_SM>().enabled = true;
|
|
ParticleSystem component4 = ParticleCloudsB.GetComponent<ParticleSystem>();
|
|
if (component4 != null)
|
|
{
|
|
ParticleSystem.EmissionModule emission4 = component4.emission;
|
|
emission4.enabled = false;
|
|
}
|
|
ParticleCloudsB.GetComponent<VolumeClouds_SM>().enabled = false;
|
|
}
|
|
ParticleCloudsA.GetComponent<VolumeClouds_SM>().LightShaderModifier = 0.3f;
|
|
ParticleCloudsA.GetComponent<VolumeClouds_SM>().minLightShaderModifier = 0.3f;
|
|
ParticleCloudsA.GetComponent<VolumeClouds_SM>().GlowShaderModifier = 0.1f;
|
|
ParticleCloudsA.GetComponent<VolumeClouds_SM>().IntensityShaderModifier = 0.35f;
|
|
}
|
|
if (activeSky == 1)
|
|
{
|
|
if (!made_onceB)
|
|
{
|
|
ParticleCloudsB.SetActive(value: true);
|
|
ParticleSystem component5 = ParticleCloudsB.GetComponent<ParticleSystem>();
|
|
if (component5 != null)
|
|
{
|
|
ParticleSystem.EmissionModule emission5 = component5.emission;
|
|
emission5.enabled = true;
|
|
}
|
|
ParticleCloudsB.GetComponent<VolumeClouds_SM>().enabled = true;
|
|
ParticleSystem component6 = ParticleCloudsA.GetComponent<ParticleSystem>();
|
|
if (component6 != null)
|
|
{
|
|
ParticleSystem.EmissionModule emission6 = component6.emission;
|
|
emission6.enabled = false;
|
|
}
|
|
ParticleCloudsA.GetComponent<VolumeClouds_SM>().enabled = false;
|
|
made_onceB = true;
|
|
}
|
|
else
|
|
{
|
|
ParticleSystem component7 = ParticleCloudsB.GetComponent<ParticleSystem>();
|
|
if (component7 != null)
|
|
{
|
|
ParticleSystem.EmissionModule emission7 = component7.emission;
|
|
emission7.enabled = true;
|
|
}
|
|
ParticleCloudsB.GetComponent<VolumeClouds_SM>().enabled = true;
|
|
ParticleSystem component8 = ParticleCloudsA.GetComponent<ParticleSystem>();
|
|
if (component8 != null)
|
|
{
|
|
ParticleSystem.EmissionModule emission8 = component8.emission;
|
|
emission8.enabled = false;
|
|
}
|
|
ParticleCloudsA.GetComponent<VolumeClouds_SM>().enabled = false;
|
|
}
|
|
ParticleCloudsB.GetComponent<VolumeClouds_SM>().LightShaderModifier = 0.3f;
|
|
ParticleCloudsB.GetComponent<VolumeClouds_SM>().minLightShaderModifier = 0.3f;
|
|
ParticleCloudsB.GetComponent<VolumeClouds_SM>().GlowShaderModifier = 0.1f;
|
|
ParticleCloudsB.GetComponent<VolumeClouds_SM>().IntensityShaderModifier = 0.35f;
|
|
}
|
|
}
|
|
else if (VolCloud != 5)
|
|
{
|
|
ParticleCloudsA.GetComponent<VolumeClouds_SM>().enabled = false;
|
|
ParticleSystem component9 = ParticleCloudsA.GetComponent<ParticleSystem>();
|
|
if (component9 != null)
|
|
{
|
|
ParticleSystem.EmissionModule emission9 = component9.emission;
|
|
emission9.enabled = false;
|
|
}
|
|
ParticleCloudsB.GetComponent<VolumeClouds_SM>().enabled = false;
|
|
ParticleSystem component10 = ParticleCloudsB.GetComponent<ParticleSystem>();
|
|
if (component10 != null)
|
|
{
|
|
ParticleSystem.EmissionModule emission10 = component10.emission;
|
|
emission10.enabled = false;
|
|
}
|
|
SUNMASTER.VolCloudGradients = true;
|
|
}
|
|
}
|
|
if (VolCloud == 5 && SUNMASTER.windZone != null)
|
|
{
|
|
VolumeClouds_SM component11 = ParticleCloudsA.GetComponent<VolumeClouds_SM>();
|
|
component11.Wind_holder = SUNMASTER.windZone.gameObject;
|
|
component11.wind = SUNMASTER.windZone.transform.forward * SUNMASTER.windZone.windMain * SUNMASTER.AmplifyWind * 0.1f;
|
|
VolumeClouds_SM component12 = ParticleCloudsB.GetComponent<VolumeClouds_SM>();
|
|
component12.Wind_holder = SUNMASTER.windZone.gameObject;
|
|
component12.wind = SUNMASTER.windZone.transform.forward * SUNMASTER.windZone.windMain * SUNMASTER.AmplifyWind * 0.1f;
|
|
}
|
|
GUI.TextArea(new Rect(5f * (num + num3), 1f * num2, num, 20f), "Wave height");
|
|
WaterHandler.waterScaleOffset.y = GUI.HorizontalSlider(new Rect(5f * (num + num3), 1f * num2 + 25f, num, 20f), WaterHandler.waterScaleOffset.y, 0f, 3f);
|
|
GUI.TextArea(new Rect(11f * (num + num3), 1f * num2 + 50f + 50f, num, 20f), "Boat Speed");
|
|
WaterHeightHandle.BoatSpeed = GUI.HorizontalSlider(new Rect(11f * (num + num3), 1f * num2 + 25f + 50f + 50f, num, 20f), WaterHeightHandle.BoatSpeed, 0.3f, 5f);
|
|
if (GUI.Button(new Rect(10f * (num + num3), 1f * num2 + 50f + 50f, num, 20f), "Reset Water"))
|
|
{
|
|
WaterHandler.FresnelOffset = 0f;
|
|
WaterHandler.FresnelBias = 0f;
|
|
WaterHandler.BumpFocusOffset = 0f;
|
|
WaterHandler.DepthColorOffset = 0f;
|
|
WaterHandler.ShoreBlendOffset = 0f;
|
|
WaterHandler.volumeFogDensityUnderwater = 50f;
|
|
WaterHandler.autoColorfogBrightness = 0.77f;
|
|
WaterHandler.fogBias = 2f;
|
|
WaterHandler.GradTransp = 0.7f;
|
|
WaterHandler.GradReflIntensity = 0.7f;
|
|
}
|
|
if (GUI.Button(new Rect(10f * (num + num3), 1f * num2 + 50f + 50f + 25f, num, 20f), "Water Controls"))
|
|
{
|
|
if (offsetsON)
|
|
{
|
|
offsetsON = false;
|
|
}
|
|
else
|
|
{
|
|
offsetsON = true;
|
|
}
|
|
}
|
|
if (offsetsON)
|
|
{
|
|
GUI.TextArea(new Rect(9f * (num + num3), 1f * num2 + 50f + 50f + 50f + 2f, num * 1f, 20f), "Fresnel Power");
|
|
WaterHandler.FresnelOffset = GUI.HorizontalSlider(new Rect(9f * (num + num3), 1f * num2 + 25f + 50f + 50f + 50f, num * 3f, 20f), WaterHandler.FresnelOffset, -0.5f, 1.7905f);
|
|
GUI.TextArea(new Rect(9f * (num + num3), 1f * num2 + 50f + 50f + 100f, num * 1f, 20f), "Fresnel Bias");
|
|
WaterHandler.FresnelBias = GUI.HorizontalSlider(new Rect(9f * (num + num3), 1f * num2 + 25f + 50f + 50f + 100f, num * 3f, 20f), WaterHandler.FresnelBias, -130f, 240f);
|
|
GUI.TextArea(new Rect(9f * (num + num3), 1f * num2 + 50f + 50f + 150f, num * 1f, 20f), "Specular focus");
|
|
WaterHandler.BumpFocusOffset = GUI.HorizontalSlider(new Rect(9f * (num + num3), 1f * num2 + 25f + 50f + 50f + 150f, num * 3f, 20f), WaterHandler.BumpFocusOffset, -4f, 4f);
|
|
GUI.TextArea(new Rect(9f * (num + num3), 1f * num2 + 50f + 50f + 200f, num * 1f, 20f), "Depth Offset");
|
|
WaterHandler.ShoreBlendOffset = GUI.HorizontalSlider(new Rect(9f * (num + num3), 1f * num2 + 25f + 50f + 50f + 200f, num * 3f, 20f), WaterHandler.ShoreBlendOffset, -0.155f, 0.1f);
|
|
GUI.TextArea(new Rect(9f * (num + num3), 1f * num2 + 50f + 50f + 250f, num * 1f, 20f), "Depth FX");
|
|
WaterHandler.DepthColorOffset = GUI.HorizontalSlider(new Rect(9f * (num + num3), 1f * num2 + 25f + 50f + 50f + 250f, num * 3f, 20f), WaterHandler.DepthColorOffset, -140f, 100f);
|
|
GUI.TextArea(new Rect(9f * (num + num3), 1f * num2 + 50f + 50f + 300f, num * 2f, 20f), "Underwater Fog Density");
|
|
WaterHandler.volumeFogDensityUnderwater = GUI.HorizontalSlider(new Rect(9f * (num + num3), 1f * num2 + 25f + 50f + 50f + 300f, num * 3f, 20f), WaterHandler.volumeFogDensityUnderwater, 0f, 500f);
|
|
GUI.TextArea(new Rect(9f * (num + num3), 1f * num2 + 50f + 50f + 350f, num * 1f, 20f), "Fog Brightness");
|
|
WaterHandler.autoColorfogBrightness = GUI.HorizontalSlider(new Rect(9f * (num + num3), 1f * num2 + 25f + 50f + 50f + 350f, num * 3f, 20f), WaterHandler.autoColorfogBrightness, -0.5f, 2f);
|
|
GUI.TextArea(new Rect(9f * (num + num3), 1f * num2 + 50f + 50f + 400f, num * 1f, 20f), "Fog depth");
|
|
WaterHandler.fogBias = GUI.HorizontalSlider(new Rect(9f * (num + num3), 1f * num2 + 25f + 50f + 50f + 400f, num * 3f, 20f), WaterHandler.fogBias, 0f, 4f);
|
|
GUI.TextArea(new Rect(9f * (num + num3), 1f * num2 + 50f + 50f + 450f, num * 2f, 20f), "Transparency");
|
|
WaterHandler.GradTransp = GUI.HorizontalSlider(new Rect(9f * (num + num3), 1f * num2 + 25f + 50f + 50f + 450f, num * 3f, 20f), WaterHandler.GradTransp, 0f, 1f);
|
|
GUI.TextArea(new Rect(9f * (num + num3), 1f * num2 + 50f + 50f + 500f, num * 1f, 20f), "Reflect power");
|
|
WaterHandler.GradReflIntensity = GUI.HorizontalSlider(new Rect(9f * (num + num3), 1f * num2 + 25f + 50f + 50f + 500f, num * 3f, 20f), WaterHandler.GradReflIntensity, 0f, 1f);
|
|
GUI.TextArea(new Rect(6f * (num + num3), 1f * num2 + 50f + 50f + 450f, num * 2f, 20f), "Volume fog Density");
|
|
SUNMASTERAH.Mesh_Terrain_controller.fogDensity = GUI.HorizontalSlider(new Rect(6f * (num + num3), 1f * num2 + 25f + 50f + 50f + 450f, num * 3f, 20f), SUNMASTERAH.Mesh_Terrain_controller.fogDensity, 0f, 500f);
|
|
GUI.TextArea(new Rect(6f * (num + num3), 1f * num2 + 50f + 50f + 500f, num * 2f, 20f), "Volume fog Height");
|
|
SUNMASTERAH.Mesh_Terrain_controller.AddFogHeightOffset = GUI.HorizontalSlider(new Rect(6f * (num + num3), 1f * num2 + 25f + 50f + 50f + 500f, num * 3f, 20f), SUNMASTERAH.Mesh_Terrain_controller.AddFogHeightOffset, -150f, 200f);
|
|
}
|
|
if (GUI.Button(new Rect(11f * (num + num3), 0f, num, 22f), "Smoke & FX") && smokeSPOT != null)
|
|
{
|
|
if (smokeSPOT.gameObject.activeInHierarchy)
|
|
{
|
|
smokeSPOT.gameObject.SetActive(value: false);
|
|
}
|
|
else
|
|
{
|
|
smokeSPOT.gameObject.SetActive(value: true);
|
|
WaterHandler.waterScaleOffset.y = 0f;
|
|
WaterHandler.waterType = WaterHandlerSM.WaterPreset.Atoll;
|
|
}
|
|
}
|
|
if (windowsON == 0)
|
|
{
|
|
if (GUI.Button(new Rect(1f * (num + num3), 0f, num, 22f), "Enter Cave") && Camera.main != null)
|
|
{
|
|
Camera.main.transform.parent = windowsSpot;
|
|
Camera.main.transform.forward = windowsSpot.forward;
|
|
Camera.main.transform.localPosition = new Vector3(-0.5f, 1.65f, -2.4f);
|
|
windowsON = 1;
|
|
WaterHandler.waterType = WaterHandlerSM.WaterPreset.River;
|
|
WaterHeightHandle.BoatSpeed = 0.3f;
|
|
WaterHeightHandle.SampleCube.position = new Vector3(boatSpot2.position.x, WaterHeightHandle.SampleCube.position.y, boatSpot2.position.z);
|
|
WaterHeightHandle.start_pos = new Vector3(boatSpot2.position.x, WaterHeightHandle.SampleCube.position.y, boatSpot2.position.z);
|
|
WaterHandler.transform.position = new Vector3(boatSpot2.position.x, WaterHandler.transform.position.y, boatSpot2.position.z);
|
|
WaterHandler.DisableUnderwater = true;
|
|
}
|
|
}
|
|
else if (windowsON == 1)
|
|
{
|
|
if (GUI.Button(new Rect(1f * (num + num3), 0f, num, 22f), "Underwater") && Camera.main != null)
|
|
{
|
|
Camera.main.transform.parent = underwaterSpot;
|
|
Camera.main.transform.localPosition = new Vector3(0f, 0f, 0f);
|
|
WaterHeightHandle.controlBoat = true;
|
|
WaterHeightHandle.LerpMotion = true;
|
|
windowsON = 2;
|
|
WaterHandler.DisableUnderwater = false;
|
|
WaterHandler.DisableUnderwater = false;
|
|
}
|
|
}
|
|
else if (windowsON == 2)
|
|
{
|
|
if (GUI.Button(new Rect(1f * (num + num3), 0f, num, 22f), "Atoll View") && Camera.main != null)
|
|
{
|
|
Camera.main.transform.parent = AtollViewSpot;
|
|
Camera.main.transform.localPosition = new Vector3(0f, 0f, 0f);
|
|
Camera.main.transform.up = Vector3.up;
|
|
WaterHeightHandle.controlBoat = true;
|
|
WaterHeightHandle.LerpMotion = true;
|
|
windowsON = 3;
|
|
WaterHandler.DisableUnderwater = false;
|
|
WaterHandler.waterType = WaterHandlerSM.WaterPreset.Atoll;
|
|
WaterHandler.DisableUnderwater = true;
|
|
Pillars.gameObject.SetActive(value: true);
|
|
}
|
|
}
|
|
else if (GUI.Button(new Rect(1f * (num + num3), 0f, num, 22f), "Board boat") && Camera.main != null)
|
|
{
|
|
Camera.main.transform.parent = WaterHeightHandle.SampleCube;
|
|
Camera.main.transform.forward = WaterHeightHandle.SampleCube.forward;
|
|
Camera.main.transform.localPosition = new Vector3(-0.5f, 2.25f, 0.34f);
|
|
WaterHeightHandle.controlBoat = true;
|
|
WaterHeightHandle.LerpMotion = true;
|
|
windowsON = 0;
|
|
Pillars.gameObject.SetActive(value: false);
|
|
WaterHeightHandle.start_pos = oceanSpot.position;
|
|
WaterHeightHandle.SampleCube.position = boatSpot.position;
|
|
WaterHandler.DisableUnderwater = false;
|
|
WaterHandler.waterType = WaterHandlerSM.WaterPreset.River;
|
|
WaterHeightHandle.BoatSpeed = 1.2f;
|
|
WaterHandler.transform.position = new Vector3(oceanSpot.position.x, WaterHandler.transform.position.y, oceanSpot.position.z);
|
|
WaterHandler.DisableUnderwater = true;
|
|
}
|
|
if (activeSky == 0 && ((SUNMASTER.currentWeather != null && SUNMASTER.currentWeather.currentState != WeatherSM.Volume_Weather_State.FadeIn) | (SUNMASTER.currentWeather == null)))
|
|
{
|
|
if (GUI.Button(new Rect(2f * (num + num3), 0f, num, 22f), "Cloudy"))
|
|
{
|
|
SUNMASTER.currentWeatherName = SkyMasterManager.Volume_Weather_types.Cloudy;
|
|
SUNMASTER.volumeClouds.EnableLightning = false;
|
|
}
|
|
if (GUI.Button(new Rect(3f * (num + num3), 0f, num, 22f), "Snow"))
|
|
{
|
|
SUNMASTER.currentWeatherName = SkyMasterManager.Volume_Weather_types.SnowStorm;
|
|
SUNMASTER.volumeClouds.EnableLightning = false;
|
|
}
|
|
if (GUI.Button(new Rect(4f * (num + num3), 0f, num, 22f), "Heavy Storm"))
|
|
{
|
|
SUNMASTER.currentWeatherName = SkyMasterManager.Volume_Weather_types.HeavyStorm;
|
|
SUNMASTER.volumeClouds.EnableLightning = true;
|
|
}
|
|
if (GUI.Button(new Rect(5f * (num + num3), 0f, num, 22f), "Rain"))
|
|
{
|
|
SUNMASTER.currentWeatherName = SkyMasterManager.Volume_Weather_types.Rain;
|
|
SUNMASTER.volumeClouds.EnableLightning = false;
|
|
}
|
|
if (GUI.Button(new Rect(3f * num + 10f, num2 + 60f + 30f + 31f + 31f + 31f + 31f, num * 2f, 32f), "Lightning Storm"))
|
|
{
|
|
SUNMASTER.currentWeatherName = SkyMasterManager.Volume_Weather_types.LightningStorm;
|
|
SUNMASTER.volumeClouds.EnableLightning = true;
|
|
}
|
|
}
|
|
if (SUNMASTER.currentWeatherName == SkyMasterManager.Volume_Weather_types.SnowStorm)
|
|
{
|
|
if (!Terra1.activeInHierarchy)
|
|
{
|
|
Terra1.SetActive(value: true);
|
|
}
|
|
}
|
|
else if (Terra1.activeInHierarchy)
|
|
{
|
|
Terra1.SetActive(value: false);
|
|
}
|
|
if (windowsON == 2)
|
|
{
|
|
if (GUI.Button(new Rect(7f * (num + num3), 0f, num, 22f), "Turbulent"))
|
|
{
|
|
WaterHandler.underWaterType = WaterHandlerSM.UnderWaterPreset.Turbulent;
|
|
}
|
|
if (GUI.Button(new Rect(6f * (num + num3), 0f, num, 22f), "Calm"))
|
|
{
|
|
WaterHandler.underWaterType = WaterHandlerSM.UnderWaterPreset.Calm;
|
|
}
|
|
}
|
|
else
|
|
{
|
|
if (GUI.Button(new Rect(6f * (num + num3), 30f, num, 22f), "Caribbean"))
|
|
{
|
|
WaterHandler.waterType = WaterHandlerSM.WaterPreset.Caribbean;
|
|
}
|
|
if (GUI.Button(new Rect(6f * (num + num3), 0f, num, 22f), "Lake"))
|
|
{
|
|
WaterHandler.waterType = WaterHandlerSM.WaterPreset.Lake;
|
|
}
|
|
if (GUI.Button(new Rect(10f * (num + num3), 0f, num, 22f), "Atoll"))
|
|
{
|
|
WaterHandler.waterType = WaterHandlerSM.WaterPreset.Atoll;
|
|
}
|
|
if (GUI.Button(new Rect(9f * (num + num3), 0f, num, 22f), "Dark Ocean"))
|
|
{
|
|
WaterHandler.waterType = WaterHandlerSM.WaterPreset.DarkOcean;
|
|
if (Camera.main != null)
|
|
{
|
|
WaterHeightHandle.SampleCube.position = oceanSpot.position;
|
|
WaterHeightHandle.start_pos = oceanSpot.position;
|
|
WaterHandler.DisableUnderwater = true;
|
|
Camera.main.transform.localPosition = new Vector3(-0.5f, 2.25f, 0.34f);
|
|
}
|
|
}
|
|
if (GUI.Button(new Rect(8f * (num + num3), 0f, num, 22f), "Focus Ocean"))
|
|
{
|
|
WaterHandler.waterType = WaterHandlerSM.WaterPreset.FocusOcean;
|
|
}
|
|
if (GUI.Button(new Rect(7f * (num + num3), 0f, num, 22f), "Muddy Water"))
|
|
{
|
|
WaterHandler.waterType = WaterHandlerSM.WaterPreset.Muddy;
|
|
}
|
|
if (GUI.Button(new Rect(7f * (num + num3), 30f, num, 22f), "River"))
|
|
{
|
|
WaterHandler.waterType = WaterHandlerSM.WaterPreset.River;
|
|
}
|
|
if (GUI.Button(new Rect(8f * (num + num3), 30f, num, 22f), "Small Waves"))
|
|
{
|
|
WaterHandler.waterType = WaterHandlerSM.WaterPreset.SmallWaves;
|
|
}
|
|
if (GUI.Button(new Rect(9f * (num + num3), 30f, num, 22f), "Ocean"))
|
|
{
|
|
WaterHandler.waterType = WaterHandlerSM.WaterPreset.Ocean;
|
|
if (Camera.main != null)
|
|
{
|
|
WaterHeightHandle.SampleCube.position = oceanSpot.position;
|
|
WaterHeightHandle.start_pos = oceanSpot.position;
|
|
WaterHandler.DisableUnderwater = true;
|
|
Camera.main.transform.localPosition = new Vector3(-0.5f, 2.25f, 0.34f);
|
|
}
|
|
}
|
|
}
|
|
GUI.TextArea(new Rect(11f * (num + num3), 1f * num2, num, 20f), "Water detail");
|
|
WaterHandler.bumpTilingXoffset = GUI.HorizontalSlider(new Rect(11f * (num + num3), 1f * num2 + 25f, num, 20f), WaterHandler.bumpTilingXoffset, 0.02f, 0.3f);
|
|
WaterHandler.bumpTilingYoffset = WaterHandler.bumpTilingXoffset;
|
|
GUI.TextArea(new Rect(11f * (num + num3), 2f * num2 + 20f, num, 20f), "Refraction");
|
|
WaterHandler.RefractOffset = GUI.HorizontalSlider(new Rect(11f * (num + num3), 2f * num2 + 25f + 20f, num, 20f), WaterHandler.RefractOffset, -0.2f, 2f);
|
|
GUI.TextArea(new Rect(10f * (num + num3), 1f * num2, num, 20f), "Extra Waves");
|
|
WaterHandler.ExtraWavesFactor.x = GUI.HorizontalSlider(new Rect(10f * (num + num3), 1f * num2 + 25f, num, 20f), WaterHandler.ExtraWavesFactor.x, 0f, 4f);
|
|
WaterHandler.ExtraWavesFactor.y = GUI.HorizontalSlider(new Rect(10f * (num + num3), 1f * num2 + 25f + 25f, num, 20f), WaterHandler.ExtraWavesFactor.y, 0f, 1f);
|
|
WaterHandler.ExtraWavesFactor.z = GUI.HorizontalSlider(new Rect(10f * (num + num3), 1f * num2 + 25f + 25f + 25f, num, 20f), WaterHandler.ExtraWavesFactor.z, 0f, 1f);
|
|
if (GUI.Button(new Rect(0f * (num + num3), 1f * num2 + 50f + 20f + 25f, num, 20f), "Atoll colors"))
|
|
{
|
|
if (colorsON)
|
|
{
|
|
colorsON = false;
|
|
}
|
|
else
|
|
{
|
|
colorsON = true;
|
|
}
|
|
}
|
|
if (colorsON)
|
|
{
|
|
GUI.TextArea(new Rect(1f * (num + num3), 5f * num2, num + 32f, 20f), "Base Color (RGBA)");
|
|
WaterHandler.AtollWaterColor.r = GUI.HorizontalSlider(new Rect(1f * (num + num3), 5f * num2 + 25f, num, 20f), WaterHandler.AtollWaterColor.r, 0f, 4f);
|
|
WaterHandler.AtollWaterColor.g = GUI.HorizontalSlider(new Rect(1f * (num + num3), 5f * num2 + 25f + 25f, num, 20f), WaterHandler.AtollWaterColor.g, 0f, 1f);
|
|
WaterHandler.AtollWaterColor.b = GUI.HorizontalSlider(new Rect(1f * (num + num3), 5f * num2 + 25f + 25f + 25f, num, 20f), WaterHandler.AtollWaterColor.b, 0f, 1f);
|
|
WaterHandler.AtollWaterColor.a = GUI.HorizontalSlider(new Rect(1f * (num + num3), 5f * num2 + 25f + 25f + 25f + 25f, num, 20f), WaterHandler.AtollWaterColor.a, 0f, 1f);
|
|
GUI.TextArea(new Rect(1f * (num + num3), 9f * num2, num + 32f, 20f), "Reflect Color (RGBA)");
|
|
WaterHandler.AtollReflectColor.r = GUI.HorizontalSlider(new Rect(1f * (num + num3), 9f * num2 + 25f, num, 20f), WaterHandler.AtollReflectColor.r, 0f, 4f);
|
|
WaterHandler.AtollReflectColor.g = GUI.HorizontalSlider(new Rect(1f * (num + num3), 9f * num2 + 25f + 25f, num, 20f), WaterHandler.AtollReflectColor.g, 0f, 1f);
|
|
WaterHandler.AtollReflectColor.b = GUI.HorizontalSlider(new Rect(1f * (num + num3), 9f * num2 + 25f + 25f + 25f, num, 20f), WaterHandler.AtollReflectColor.b, 0f, 1f);
|
|
WaterHandler.AtollReflectColor.a = GUI.HorizontalSlider(new Rect(1f * (num + num3), 9f * num2 + 25f + 25f + 25f + 25f, num, 20f), WaterHandler.AtollReflectColor.a, 0f, 1f);
|
|
}
|
|
_ = SPEED;
|
|
_ = 1f;
|
|
if ((SUNMASTER.Current_Time != Sun_time_start) & !set_sun_start)
|
|
{
|
|
set_sun_start = true;
|
|
}
|
|
}
|
|
|
|
private void LateUpdate()
|
|
{
|
|
if (prev_ambient != SUNMASTER.AmbientIntensity)
|
|
{
|
|
DynamicGI.UpdateEnvironment();
|
|
RenderSettings.ambientIntensity = SUNMASTER.AmbientIntensity;
|
|
prev_ambient = SUNMASTER.AmbientIntensity;
|
|
}
|
|
}
|
|
}
|
|
}
|