- Home /
buttons opacity (or alpha)
Hello everyone! I would like to make the buttons i've created using GUI.Button slowly appear. I thought about changing the opacity value during time, but there's no opacity (or alpha) value inside the GUI.Button method. Can someone give me an idea about how can i achieve this effect?
Answer by FLASHDENMARK · Sep 06, 2012 at 05:13 PM
Use:
GUI.color.a = valueFrom0To1;
just before drawing the GUI Button.
This will also work for all other GUI elements, not just buttons.
but can i control the alpha value of just one button? the effect i'm trying to realize is making the buttons appear one after the other.
ok, i've done, i just needed to rewrite GUI.color.a before evry GUI.Button and than changing their values dinamically, thank you very much!
Remember to accept the answer and vote it up. You got a large amount of unaccepted answers(not sure if they actually answered your question, but I thought I would re$$anonymous$$d you anyway).