- Home /
Question by
pryankster · Jul 29, 2015 at 07:46 AM ·
buttonspritengui
NGUI button: Different sizes for different states?
I have some artwork for NGUI buttons:
Unpressed button:
Pressed button:
I'd like to use them as sprite-swaps for an NGUI button, so I import them into unity and set them up for nine-slices, but as the sprite for the pressed button is shorter than the sprite for the unpressed button, the pressed button is stretched upward to fill the same space as the unpressed button. Is my only solution to just include some whitespace above the button?
button-3-1.png
(11.2 kB)
button-3-3.png
(11.5 kB)
Comment
I think adding a transparent part to match the size is the easiest option, unless you want to create you own UI classes.