0
\$\begingroup\$

I have a scroll view with lots of buttons on it. when i press one button, that button needs to change the sprite and stay like that. if any other button (or same one) is pressed previous button needs to revert back to original sprite.. here is some example enter image description here

button 2 was pressed and changed sprite, it stays like that untill it is pressed again or any other (in this case button 3) is pressed

\$\endgroup\$
1
  • \$\begingroup\$ Try rephrasing this in a way that turns it into a question. I'm unsure what information you are looking for. \$\endgroup\$ Commented Jan 20, 2016 at 16:48

1 Answer 1

0
\$\begingroup\$

You should use UIToggle with Toggle Group instead of doing it manually.

You can create multiple Toggle buttons having same Toggle Group then so only one button (toggle button) will be enabled at a time.

\$\endgroup\$
1
  • \$\begingroup\$ Thank you, i used your advice to learn more about toggles in unity and they work like charm.. \$\endgroup\$ Commented Jan 23, 2016 at 10:47

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.