10-18-2004, 08:03 AM | #1 (permalink) |
Insane
|
Flash help
I am making a drop down menu in flash.
I have a small movie clip with the actionscript: Code:
on(rollOver){ gotoAndPlay("over"); } on(rollOut){ gotoAndPlay("out"); } This works fine, but when I try and add a button to the menu, it will either be unclickable (if inside the movie clip) or it will flip out, if it is laid on top of the clip. Take a look Any help would be much appreciated.
__________________
I know I was born and I know that I'll die, the inbetween is mine. |
10-19-2004, 04:44 AM | #4 (permalink) |
Insane
|
Well guys, I took the rollOut code off and put an invisible button around the the menu that makes the menu disappear on rollOver, and it seemed to do the trick.
Ultimate_Goham - I tried the hitTest thing, and couldn't really get it working. I'm an amateur with the actionscript. I might pick up an actionscript book, got any suggestions?
__________________
I know I was born and I know that I'll die, the inbetween is mine. |
10-19-2004, 05:41 AM | #5 (permalink) |
Crazy
Location: UK
|
Flash help...
What you've done works well until you place another button in the movie and then the rollOver & rollOut commands get confused...
I found from bitter experience that you need to assigned a variable (in my version: VariableNamedWhatever) to make this work: ---Code for the Invisible button--- on (rollOver) { VariableNamedWhatever = "1"; tellTarget ("over") { play(); } } on (rollOut) { VariableNamedWhatever = "2"; gotoAndPlay(3); tellTarget ("out") { stop(); } } ---Code for Frame 3--- if (Number(VariableNamedWhatever) == 1) { tellTarget ("over") { play (); } } Hope this helps...?
__________________
and so ends the thought process for another day... |
Tags |
flash |
|
|