rollingcodes
rollingcodes

Reputation: 16072

ActionScript Flash Predefined Global Variables

Can anyone send me a link, or list all of the global variables that are predefined by Flash ActionScript 3? For example, like the current time, or the current frame, etc.?

Thanks, Thommy

Upvotes: 0

Views: 234

Answers (2)

user346443
user346443

Reputation: 4862

Im not too sure if there is any. Generally you would use the stage or main movieClip object.

trace("frame: " + myMovieClip.currentFrame);

var now:Date = new Date();
trace("time: " + now.getTime());

I usually use a singleton pattern if i need global variables.

Upvotes: 1

divillysausages
divillysausages

Reputation: 8053

Your best bet is the language reference: http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/all-index-Symbols.html

If by global variables, you mean Top Level classes/functions etc, you can check out: http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/package-detail.html

Upvotes: 1

Related Questions