private void OnEnable() { if (WeatherMakerScript.Instance == null) { return; } WeatherMakerScript.EnsureInstance(this, ref instance); if (WeatherMakerCommandBufferManagerScript.Instance != null) { WeatherMakerCommandBufferManagerScript.Instance.RegisterPreCull(CameraPreCull, this); WeatherMakerCommandBufferManagerScript.Instance.RegisterPreRender(CameraPreRender, this); WeatherMakerCommandBufferManagerScript.Instance.RegisterPostRender(CameraPostRender, this); } skySphereMaterial.Update(MeshRenderer.sharedMaterial); if (SkySphereProfile == null) { SkySphereProfile = WeatherMakerScript.Instance.LoadResource <WeatherMakerSkyProfileScript>("WeatherMakerSkyProfile_Procedural"); } if (SkySphereProfile.AtmosphereProfile == null) { SkySphereProfile.AtmosphereProfile = WeatherMakerScript.Instance.LoadResource <WeatherMakerAtmosphereProfileScript>("WeatherMakerAtmosphereProfile_Default"); } if (SkySphereProfile.AtmosphereProfile != null) { SkySphereProfile.AtmosphereProfile.UpdateShaderVariables(null, AtmosphereLookupMaterial, AtmosphereComputeShader); } }
private void OnEnable() { WeatherMakerScript.EnsureInstance(this, ref instance); if (WeatherMakerCommandBufferManagerScript.Instance != null) { WeatherMakerCommandBufferManagerScript.Instance.RegisterPreCull(CameraPreCull, this); } }
private void OnEnable() { WeatherMakerScript.EnsureInstance(this, ref instance); if (cloudParticleSystem != null && wasPlaying) { cloudParticleSystem.Play(); } }
/// <summary> /// OnEnable /// </summary> protected override void OnEnable() { base.OnEnable(); WeatherMakerScript.EnsureInstance(this, ref instance); if (WeatherMakerCommandBufferManagerScript.Instance != null) { WeatherMakerCommandBufferManagerScript.Instance.RegisterPreCull(CameraPreCull, this); WeatherMakerCommandBufferManagerScript.Instance.RegisterPreRender(CameraPreRender, this); WeatherMakerCommandBufferManagerScript.Instance.RegisterPostRender(CameraPostRender, this); } }
private void OnEnable() { WeatherMakerScript.EnsureInstance(this, ref instance); }
protected override void OnEnable() { WeatherMakerScript.EnsureInstance(this, ref instance); CommandBufferName = "WeatherMakerFullScreenSnowOverlayScript"; base.OnEnable(); }
protected virtual void OnEnable() { WeatherMakerScript.EnsureInstance(this, ref instance); }