Mecanim to scale UI Transform Rect
I am using Mecanim and Animation to create a "Drawer" UI window. One that can Scale up (and hide) like a drawer closing, and scale down (and show) like the drawer opening. Same for a horizontal drawer. This all works great with actual Size delta.y pixel/unit changes.
Now I would like to create a generic animation that scales up and down and left and right based on a percent change of Size delta.y. So for 0 the drawer is closed, for 1 the drawer is open. So it can be applied to any size window. Instead of having to generate an animation per drawer/window.
Any ideas or hints of what I need to be looking at?
Essentially I want to change Size delta.y and Size delta.x in animation based on percent.
Thanks
Your answer
![](https://koobas.hobune.stream/wayback/20220612115242im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Can I make a dynamic wave ui with shader ? 0 Answers
Hey people i want to know is there a way to play animation for the first time player plays 1 Answer
Cursor dissapearing in my menu 0 Answers
How to enable and disable a UI panel with animations? 0 Answers
How can I 'instantly' reset my state machine back to its first state to replay my animation? 0 Answers