topical media & game development

talk show tell print

actionscript-wii-Ball.ax

actionscript-wii-Ball.ax [swf] flex


  package {
          import flash.display.Sprite;
          
          public class @ax-actionscript-wii-Ball extends Sprite {
                  public var radius:Number;
                  private var color:uint;
                  public var vx:Number = 0;
                  public var vy:Number = 0;
                  
                  public function @ax-actionscript-wii-Ball(radius:Number=40, color:uint=0xff0000) {
                          this.radius = radius;
                          this.color = color;
                          init();
                  }
                  public function init():void {
                          graphics.beginFill(color);
                          graphics.drawCircle(0, 0, radius);
                          graphics.endFill();
                  }
          }
  }


(C) Æliens 27/08/2009

You may not copy or print any of this material without explicit permission of the author or the publisher. In case of other copyright issues, contact the author.