-
I am pretty new to variables and need to know how to set a variable, and then work actions on a seperate button and mc accordingly.
My problem is I want to find which frame an mc is on by using variables, then use an if statement on a button to tell the mc to go somewhere else.
I hope this makes sense.
-
Senior Member
you can do this with action on some mc
onClipEvent(enterFrame){
Frame=_root._currentFrame;
}
and buttonAction
if(_root.Frame==...){
do...
}
hope that helps...
-
i still can't get it working.
it either plays the mc anyway, or it doesnt play it at all.
i need the button in a seperate mc to check what frame another mc is in, and then choose what to do accordingly.
-
Senior Member
try this:
button action
on(press){
Frame=_root.anotherMC._currentFrame;
If (Frame==...){...}
}
this one works. I tryed it.
-
Senior Member
You can try also trace variable Frame like
on(press){
Frame=_root.anotherMC._currentFrame;
trace(Frame);
If (Frame==...){...}
}
-
worked worked worked thanks mate bo bo bo
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|