[16558-hm.zip|16558]Hi,
Current I’m working on a project with a menu bar like this.
[16554-ask+copy.png|16554]
I already can make this menu bar show / hide with LeanTween . But the animation is horrible . Button’s animation and Menu’s animation can’t running both smoothly.
Here are the code currently i’m using :
if (GUI.Button (expandButton.rect, curImg,style)) {
if (isExpanded) {
isExpanded = false;
//move down
LeanTween.move (expandButton, new Vector2 (sWidth / 2 - 15, sHeight - 20), 0.8f);
LeanTween.move (menuContainer, new Vector2 (0, sHeight + 50), 0.8f);
else{
isExpanded = true;
//move up
LeanTween.move (expandButton, new Vector2 (sWidth / 2 - 15, sHeight - 70), 0.8f);
LeanTween.move (menuContainer, new Vector2 (0, sHeight - 50), 0.8f);
}
Any suggestion on this problem ?