Quantcast
Channel: UGUI & TextMesh Pro
Viewing all articles
Browse latest Browse all 23263

Changing the color of a UI Button with scripting?

$
0
0
I'm trying to change the color of a button depending on an array. Is there any way I can dynamically change the color of a button? It should be under the image class, but it's not.

If not, can I do a similar procedure, but with sprites? In the future, I plan to change the sprite based on the array, but until then I want to just use colors for debugging. Or I could just add dumb images.

Problem solved, was easy. I just didn't think it through.

Viewing all articles
Browse latest Browse all 23263

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>