Search Unity

  1. Get all the Unite Berlin 2018 news on the blog.
    Dismiss Notice
  2. Unity 2018.2 has arrived! Read about it here.
    Dismiss Notice
  3. Improve your Unity skills with a certified instructor in a private, interactive classroom. Learn more.
    Dismiss Notice
  4. ARCore is out of developer preview! Read about it here.
    Dismiss Notice
  5. Magic Leap’s Lumin SDK Technical Preview for Unity lets you get started creating content for Magic Leap One™. Find more information on our blog!
    Dismiss Notice
  6. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice

CanvasRenderer OnEnable SetAlpha

Discussion in 'Unity UI & TextMesh Pro' started by Piflik, Mar 23, 2016.

  1. Piflik

    Piflik

    Joined:
    Sep 11, 2011
    Posts:
    212
    I am using the CanvasRenderer.SetAlpha() function to fade out UI elements. It works well most of the time, but at one position I deactivate gemeobjects, and when they are activated again, the CanvasRenderer's alpha value is reset to 1 instead of keeping the value it had before. Is that the intended behaviour?

    Edit: A short test tells me it already happens in OnDisable() (or earlier, Debug.Log in OnDisable returns 1, while in Update it prints the correct value)
     
    Menion-Leah likes this.
  2. Menion-Leah

    Menion-Leah

    Joined:
    Nov 5, 2014
    Posts:
    39
    Issue still present in 2017.3.0p1