flash menu help
- Started
- Last post
- 9 Responses
- kinetic
i have a vertical menu in flash with like 20 buttons in it or so...what i need to do is every 10 seconds or so..move the menu up 1 button.
it has to be coded too (no tweening) because if the user clicks a button at the bottom of the screen, that button will take the top spot (it has to scroll that button to the top).. and then stop for another 10 seconds
i searched on flashkit but couldn't find anything useful
anyone know of a .fla out there with function like this? or can anyone offere a suggestion.
one thing i thought was .i made all the buttons 75 pixels in height..so it only has to -75 from the Y each time to scroll...so at the end of 20 frames i make a var called buttonY -=75 .. then in the menu MC i have an onClipEvent(enterFrame) that scrolls based on that var...my only prob with this is starting and stopping the scroll
any help on this is much appreciated..im pretty stuck on this one
thanks :)
- unfittoprint0
//slide menu's _y
function changeY (targety){
movieY=menu._y;
movieY += (targety-movieY)/5;
menu._y=movieY;
};//update Y (increment increases
//a menu's _y equal amout each
//time is refreshedupdate = function(increment){
targetY += increment
clearInterval(updateY)
updateY = setInterval(this, "changeY", 30, targetY)
}delay = setInterval(this, "update", 2000);
stop()
- kinetic0
my goodness!
thanks unfittoprint!!!!
:)
- kinetic0
for some reason it only seems to fire once....and i cant get the slide values right
i have this:
function changeY (targety){
movieY = buttons_menu._y;
movieY += (targety-movieY)/5;
buttons_menu._y = movieY;
};update = function(increment){
targetY += increment
clearInterval(updateY)
updateY = setInterval(this, "changeY", 30, targetY)
}delay = setInterval(this, "update", 2000);
stop()that should move it up every 2 seconds
- unfittoprint0
ooops...
you'll have to give the increment before setting the delay interval... so before the delay put:
increment = 70; //for example
delay = setInterval(this, "update", 2000, increment);
stop()
- Louno0
hehe that was fast anwser , try this one , im trying to make a cms in flash , could you post the action script for that please ?
- kinetic0
hahaha
unfittoprint you are the bomb mate!
and Louno...if i had the AS for a flash CMS..id post it for ya ;)
one thing...unfit...when it first hits that code for some reason it scrolls it up quite a lot...then the next interval it scrolls it by the increment = -75; that i set
not quite sure why it happens
thanks again for all your help on this man...i really appreciate it
- bomy_dick0
god..
unfit is unreal..
- kinetic0
nevermind..figured it out...had to reset the X and Y of the inside of the MC to 0
Thanks again unfit!!! YOU ROCK!!! :D
- JazX0
don't fuck with unfit's Flash knowledge. he's a bloody GOD