Hello flash coders,

in my document class I check loaderInfo.parameters.debug:

public class MyGame extends Sprite {
        public static const DEBUG:Boolean = loaderInfo.parameters.debug;
        public static const SERVER:String = DEBUG ? 'http://192.168.111.43' :
'http://preferans.de';
        public static const INTERVAL:uint = (DEBUG ? 60 : 15) * 1000;

and this way I can switch on debugging mode in my game
by loading MyGame.swf?debug=1 in the browser tab.

But how can I access the loaderInfo.parameters.debug
from other custom MovieClips/Sprites in my application?

I do not want to check for MyGame.DEBUG, because
I'm trying to keep the code in separate "modules" -
i.e. I have for example files User.as and UserTest.fla
and can compile and test that class without the MyGame.as

Regards
Alex
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to