- Home /
This question was
closed Mar 20, 2020 at 07:37 AM by
jiny90 for the following reason:
The question is answered, right answer was accepted
Question by
jiny90 · Mar 20, 2020 at 12:33 AM ·
buttonimagespressedbutton backround
Images on button don't change transparency when button pressed.
I am a newbie in Unity.
I add images on button, but this images don't change transparency when button clicked.
Normal Button
Pressed Button
I want "clear!!" image changes transparency, too.
How can I?
button.png
(15.3 kB)
button-clicked.png
(16.4 kB)
Comment
Add a canvas group to the parent button, and an event trigger component. to the OnPointerDown event, attach a listener that changes the canvasgroup alpha in code. Reset it in OnPointerUp event