-
Flash Incompetent
[F8] Variables from one MC to another
I'm probably violating a FK rule here, but I posted my problem in the actionscript forum and got no love, no responses! I don't like to venture out of the games section but felt my question better fit in there... anyways, I was wrong. I hope my faith in the games section to help me out will be affirmed. Anyways the question is:
So i have a timeline with 2 frames, first frame has a movie clip on it called Game, I define a bunch of variables in it, once the game is played it goes to the next frame on the main timeline, called score. How do I go about accessing the variables from movie clip Game in the movie clip Score? I tried _root.Game.variable, I tried _level0.Game.variable nothing seems to work... not sure how to solve this problem. I'm praying I don't need to redefine all the variables to _root.variable so that they can be accessed by both MC's...
it can be found here. Sorry about posting in multiple places but my question was ignored.
Thanks in advance,
ChaseNYC
-
Senior Member
If the movieclip is not in the second frame, then all the variables are gone. declare a new variable in root and give it the value you want.
-
Flash Incompetent
hmmm so maybe a better solution would be to put the score MC on the second frame of the game MC? instead of telling _root.nextFrame() just this.nextFrame()... I get so confused how to structure things to keep them organized...
thanks,
ChaseNYC
edit: thanks so much, now I don't see why no one in actionscript section couldn't have told me that... I guess games is just the most awesomest section.
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
|