HOMERSS 2.0RSS comments
sizeSMALLMEDIUMLARGEXTRA LARGE
home
time
44/Tue
10 28 08 20 00
title mediaMultiMedia
title
類
論
別

Just forgot to mention that I made a blog for my new prefix “professor” in Kean university.

If you are interested in learning flash or checking out some AS3 for Flash IDE example I used in class, you can go to mediamultimedia.wordpress.com

If you are pretty new to Flash / AS3, there are some Flash IDE based examples in class blog for people to download.


  • 恩... 1 Stars喔~ 2 Stars好! 3 Stars酷!! 4 Stars哇!!! 5 Stars (4 票, 平均: 4.5 / 5) << 請踴躍投票

    time
    40/Tue
    09 30 08 00 41
    title AS3筆記-get stage
    title
    類
    論
    別

    If you want to build something like keyboard shortcut or want to catch global mouse activity, you might need to use

    
    stage.addEventListener(KeyboardEvent.KEY_DOWN,onKeyPressed);
    //or
    stage.addEventListener(MouseEvent.CLICK,onMouseClicked);
    

    You might need to access “stage” from sub-classes. To get “stage” from document class you can try:

    
    addEventListener(Event.ADDED_TO_STAGE, onAddStage);
    private function onAddStage(evt:Event):void{
    //var myParent:Sprite=Sprite(evt.target)
    //myParent.stage.addEventListener(KeyboardEvent.KEY_DOWN,onKeyPressed);
    //sprite裡面的stage property 已經可以因為被放到Stage的事件之後被使用
    this.stage.addEventListener(KeyboardEvent.KEY_DOWN,onKeyPressed);
    }
    

  • 恩... 1 Stars喔~ 2 Stars好! 3 Stars酷!! 4 Stars哇!!! 5 Stars << 請踴躍投票

    time
    33/Thu
    08 14 08 00 24
    title AS3筆記-DisObj,Reference,GC
    title
    類
    論
    別

    如果今天new一個DisplayObject然後reference給一個property variable,addChild,之後 removeChild 然後那個property variable又reference給另一個DisplayObject.

    那原先的DisplayObject就再也access不到了對吧? 這樣子Garbage Collection會釋放出記憶體嗎?

    不管有沒有 把 reference 先設成 null,再重新 reference, GC都會把他清掉.只是快慢問題而已.好像沒有記憶體越用越多的問題….

    ex:

    b=new SpriteClassA();

    a.addChild(b);

    b.remove()//自己fadeout之後 parent.removeChild(this)

    b=new SpriteClassB();

    a.addChild(b);

    詳全文 ReadMore


  • 恩... 1 Stars喔~ 2 Stars好! 3 Stars酷!! 4 Stars哇!!! 5 Stars (1 票, 平均: 5 / 5) << 請踴躍投票

    time
    32/Wed
    08 06 08 12 55
    title AS3筆記-運動複習
    title
    類
    論
    別
    Please enable Javascript and Flash to view this Flash video.

    自從用了 TweeningEngine 之後,就漸漸忘了從前用 EnterFrame是怎麼寫物體運動的, 趁現在還記得, 放在這邊備忘…

    詳全文 ReadMore


  • 恩... 1 Stars喔~ 2 Stars好! 3 Stars酷!! 4 Stars哇!!! 5 Stars << 請踴躍投票

    time
    31/Thu
    07 31 08 18 09
    title AS3筆記-FlexSdkCompiler+FDT
    title
    類
    論
    別

    Read This:
    http://hubflanger.com/how-to-compile-an-as3-project-with-fdt/

    DownLoad This:
    http://www.adobe.com/products/flex/flexdownloads/

    THEN…

    詳全文 ReadMore


  • 恩... 1 Stars喔~ 2 Stars好! 3 Stars酷!! 4 Stars哇!!! 5 Stars (1 票, 平均: 5 / 5) << 請踴躍投票