大家應該有遇過進行小測試時,只想隨便寫個 as
要怎麼測試,又不想特別開一個 Project
更不想開肥大的 Flash CS5 IDE
那怎麼辦呢??
幸好 FlashDevelop 很好用很強大
有 build current file 這個功能
Tools -> Flash Tools -> Build Current File
or Ctrl + F8
but..compile 出來怎麼沒有 trace output?
或是想要加入某個 library.swc?
那怎麼辦??
只要在 as 檔頭加入 MXMLC options
FlashDevelop 就會自動照著 compile 了。
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @mxmlc -debug -o=bin/ClassName.swf | |
* //@mxmlc -o=bin/ClassName.swf -l=GATracking.swc | |
*/ | |
package | |
{ | |
import flash.display.Sprite; | |
public class ClassName extends Sprite | |
{ | |
public function ClassName() | |
{ | |
trace("ClassName"); | |
graphics.beginFill(0x1234567, 1); | |
graphics.drawCircle(100, 100, 100); | |
graphics.endFill(); | |
} | |
} | |
} |
沒有留言:
張貼留言