A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: Quick Question - defining variables...where can I?

  1. #1
    Member
    Join Date
    Oct 2003
    Location
    Canada
    Posts
    40

    Quick Question - defining variables...where can I?

    I have an empty SWF that's sole purpose is to call loadMovieNum and start the project. Each loaded movie has a few variables defined within them - unique to those loaded SWFs.

    Instead of declaring all the variables in each SWF can I declare all of them in one place, in the first frame of the empty loader it all starts from? I'm thinking I can then declare a variable which each loaded movie can increment as needed for me.

  2. #2
    Member
    Join Date
    Oct 2003
    Location
    Canada
    Posts
    40
    I just did a couple little tests and unless I've done something wrong, I cannot define the variables in the shell loader SWF.

    But it occurred to me that I could load a SWF into level one billion (kidding...just very high) that contains all the variables I need and then just use the _level references to reference them as I need. This top level MC will stay for the duration of the project so no fears of variables purging.

    Right?

    Feel free to stop me if I'm doing something crazy.

  3. #3
    Member
    Join Date
    Oct 2003
    Location
    Canada
    Posts
    40
    I might be crazy but it's working like a dream. Don't let that stop you from telling me a better way though.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center