protected virtual void Awake() { fadeMaterial = new Material(Shader.Find("Unlit/TransparentColor")); instance = this; }
/// <summary> /// The HeadsetFade method is used to apply a fade to the headset camera to progressively change the colour. /// </summary> /// <param name="color">The colour to fade to.</param> /// <param name="duration">The amount of time the fade should take to reach the given colour.</param> /// <param name="fadeOverlay">Determines whether to use an overlay on the fade.</param> public override void HeadsetFade(Color color, float duration, bool fadeOverlay = false) { VRTK_ScreenFade.Start(color, duration); }
private void Awake() { fadeMaterial = new Material(Shader.Find("Unlit/TransparentColor")); instance = this; }