I was wondering - has anybody figured out how to literally fade on a GUI? I really need this for my login script....
Seems obvious don't it?
Thanks! Christian Stewart
asked May 22 '10 at 02:45 PM
To fade a GUITexture object:
Just apply that script to a Game Object that has a GUITexture component and it'll fade in and out. Modify it to do whatever you need it to do. I'd suggest possibly wrapping the fade inside of a coroutine instead of Update.
To do something similar with OnGUI(), add this to the above code:
Also take a look at the other 2 properties that are similar to GUI.color in the docs to isolate more specific parts of your GUI. Since OnGUI is immediate mode and procedural you can see that just redefining the color property later on in the script will produce different results in the same pass.
Hope that helps.