How do I change color with Button onClick()
I have some ugui images with the button component. Each button is a different colour and when they're clicked i want to pass the rob value to my character script to change the colour. My buttons are named according to their her value ie #000000 so i figured it was just a matter of using on click() and converting to rub but haven't found out how.
I've tried:
Int i = int.Parse(button.name)
Anyone know how i can do this or suggest another way to achieve this?
Comment
Your answer
Follow this Question
Related Questions
Change color of button and convert string into int 1 Answer
How to get the Color Code in RGB Hex from RGBA? (Unity 3D 5.0f1) 4 Answers
Change color for disabled button 1 Answer
How to make a button unclickable when alpha = 0 1 Answer
[resolved] How do I deactivate a button once its height is < 40 in c# 0 Answers