Navigation Bar Help
Started by
/quit
, Oct 06 2005 04:15 PM
10 replies to this topic
#1
Posted 06 October 2005 - 04:15 PM
Well i'm trying to creat a navigation bar which lowers as you hover over it. But, if you slid the mouse off of it, the button, regardless of its position, will slide back up.
Here is an Example www.newelementdesigns.com
Anywho, whenever I try to do this, I would just use a simple button with animation that it slides down in "over" and slides up in the other. Is there a key piece of action script which I am missing?> Thanks in advanced,
Here is an Example www.newelementdesigns.com
Anywho, whenever I try to do this, I would just use a simple button with animation that it slides down in "over" and slides up in the other. Is there a key piece of action script which I am missing?> Thanks in advanced,
#2
Posted 08 October 2005 - 12:33 AM
there is no actionscript involved..what are you seeing? are you seeing it slide down, but when you pick your mouse up it dosent slide, it just snaps? let me know so i know how to help you.
#3
Posted 08 October 2005 - 08:28 AM
Well, its just if you hove off of it when its only in mid slide down, it will snap back up in what ever positiion its in.
#4
Posted 08 October 2005 - 09:34 AM
that's called inertia tweening.. have a search on google for it..
I can't really explain how to do it. since I never done it on my own.
I can't really explain how to do it. since I never done it on my own.
#5
Posted 08 October 2005 - 09:43 AM
OOo thanks, just having that term will actually really help me.
#6
Posted 08 October 2005 - 09:51 AM
couldn't it be done with the hover action on a simple button? and including a movie clip inside the hover of the thing coming down etc. ?
#7
Posted 08 October 2005 - 10:08 AM
no, beacuse it would keep playing (unless you put a stop), and it would not do the animation back up...
#8
Posted 08 October 2005 - 10:41 AM
it's also possible to make it with a few tweens and stop actions.. but the result will not come out so nicely as on the site he mentioned.
that nav is definately scripted.. not tweened
that nav is definately scripted.. not tweened
#9
Posted 08 October 2005 - 11:01 AM
They way you can do this is with some action script tweens and a button. You wouldn't do this inside the button you would just have the button so that they could roll over it. EX:
Make a button on frame one. On frame one add this script:
then add this script to your button:
Now on frame two you would have your tween say it is 5 frames long so it would end on frame 6 on that frame add this script:
Now to make it go up you just put this action script on the button:
Note: Remove the first script that was added to the button.
That would be the script to send it to the frame where it goes up then when it is done just let it go back gro the first frame.
hope that helped.
dEcade
Make a button on frame one. On frame one add this script:
stop();
then add this script to your button:
on(rollOver) { gotoAndPlay(2); }
Now on frame two you would have your tween say it is 5 frames long so it would end on frame 6 on that frame add this script:
stop();
Now to make it go up you just put this action script on the button:
on(rollOut) { gotoAndPlay(7); }
Note: Remove the first script that was added to the button.
That would be the script to send it to the frame where it goes up then when it is done just let it go back gro the first frame.
hope that helped.
dEcade
#10
Posted 08 October 2005 - 11:38 AM
decade: that's a fast solution, and it works also, but I think the cool thing about the nav on that site.. is that it has the easing implemented..
#11
Posted 19 October 2005 - 08:56 AM
Yeah, I know the basic of action scripting for buttons like, stop, go to, and such. But the tweening for that site was much more advanced, which is what made it appealing.
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users