// Token: 0x06000A2F RID: 2607 RVA: 0x00049BEC File Offset: 0x00047DEC private EnvSetup InterpolateEnvironment(EnvSetup a, EnvSetup b, float i) { EnvSetup envSetup = a.Clone(); envSetup.m_name = b.m_name; if (i >= 0.5f) { envSetup.m_isFreezingAtNight = b.m_isFreezingAtNight; envSetup.m_isFreezing = b.m_isFreezing; envSetup.m_isCold = b.m_isCold; envSetup.m_isColdAtNight = b.m_isColdAtNight; envSetup.m_isColdAtNight = b.m_isColdAtNight; } envSetup.m_ambColorDay = Color.Lerp(a.m_ambColorDay, b.m_ambColorDay, i); envSetup.m_ambColorNight = Color.Lerp(a.m_ambColorNight, b.m_ambColorNight, i); envSetup.m_fogColorDay = Color.Lerp(a.m_fogColorDay, b.m_fogColorDay, i); envSetup.m_fogColorEvening = Color.Lerp(a.m_fogColorEvening, b.m_fogColorEvening, i); envSetup.m_fogColorMorning = Color.Lerp(a.m_fogColorMorning, b.m_fogColorMorning, i); envSetup.m_fogColorNight = Color.Lerp(a.m_fogColorNight, b.m_fogColorNight, i); envSetup.m_fogColorSunDay = Color.Lerp(a.m_fogColorSunDay, b.m_fogColorSunDay, i); envSetup.m_fogColorSunEvening = Color.Lerp(a.m_fogColorSunEvening, b.m_fogColorSunEvening, i); envSetup.m_fogColorSunMorning = Color.Lerp(a.m_fogColorSunMorning, b.m_fogColorSunMorning, i); envSetup.m_fogColorSunNight = Color.Lerp(a.m_fogColorSunNight, b.m_fogColorSunNight, i); envSetup.m_fogDensityDay = Mathf.Lerp(a.m_fogDensityDay, b.m_fogDensityDay, i); envSetup.m_fogDensityEvening = Mathf.Lerp(a.m_fogDensityEvening, b.m_fogDensityEvening, i); envSetup.m_fogDensityMorning = Mathf.Lerp(a.m_fogDensityMorning, b.m_fogDensityMorning, i); envSetup.m_fogDensityNight = Mathf.Lerp(a.m_fogDensityNight, b.m_fogDensityNight, i); envSetup.m_sunColorDay = Color.Lerp(a.m_sunColorDay, b.m_sunColorDay, i); envSetup.m_sunColorEvening = Color.Lerp(a.m_sunColorEvening, b.m_sunColorEvening, i); envSetup.m_sunColorMorning = Color.Lerp(a.m_sunColorMorning, b.m_sunColorMorning, i); envSetup.m_sunColorNight = Color.Lerp(a.m_sunColorNight, b.m_sunColorNight, i); envSetup.m_lightIntensityDay = Mathf.Lerp(a.m_lightIntensityDay, b.m_lightIntensityDay, i); envSetup.m_lightIntensityNight = Mathf.Lerp(a.m_lightIntensityNight, b.m_lightIntensityNight, i); envSetup.m_sunAngle = Mathf.Lerp(a.m_sunAngle, b.m_sunAngle, i); envSetup.m_windMin = Mathf.Lerp(a.m_windMin, b.m_windMin, i); envSetup.m_windMax = Mathf.Lerp(a.m_windMax, b.m_windMax, i); envSetup.m_rainCloudAlpha = Mathf.Lerp(a.m_rainCloudAlpha, b.m_rainCloudAlpha, i); envSetup.m_ambientLoop = ((i > 0.75f) ? b.m_ambientLoop : a.m_ambientLoop); envSetup.m_ambientVol = ((i > 0.75f) ? b.m_ambientVol : a.m_ambientVol); envSetup.m_musicEvening = b.m_musicEvening; envSetup.m_musicMorning = b.m_musicMorning; envSetup.m_musicDay = b.m_musicDay; envSetup.m_musicNight = b.m_musicNight; return(envSetup); }
public static void AddHelheimEnvironments(EnvMan envMan, EnvSetup baseEnv, int level) { var helheimEnvBase = baseEnv.Clone(); helheimEnvBase.m_name = GetHelheimEnvName(level, false, false); //FindAndCopyEnvObjectByName(envMan, "Thunder", helheimEnvBase); envMan.m_environments.Add(helheimEnvBase); var helheimEnvWet = helheimEnvBase.Clone(); helheimEnvWet.m_name = GetHelheimEnvName(level, true, false); helheimEnvWet.m_isWet = true; FindAndCopyPsystemByName(envMan, level == 1 ? "LightRain" : "Rain", helheimEnvWet); envMan.m_environments.Add(helheimEnvWet); var helheimEnvFreezing = helheimEnvBase.Clone(); helheimEnvFreezing.m_name = GetHelheimEnvName(level, false, true); helheimEnvFreezing.m_isFreezing = true; FindAndCopyPsystemByName(envMan, level == 1 ? "Snow" : "SnowStorm", helheimEnvFreezing); envMan.m_environments.Add(helheimEnvFreezing); }