开发者

"Include" external .as files in AS3

I want to include external code without importing a custom class in 开发者_开发百科AS3. My code is getting too long and I need to find a way to segment it into logical groups of functions located in separate ActionScript files. Is this possible?


ActionScript provides the include directive to include the source of one file inside another:

include "[path]filename.as"

Includes the contents of the specified file, as if the commands in the file are part of the calling script.

(You may also see this used as #include, but the # hasn't been required since ActionScript 2.)

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜