forked from: 別のクラス複数置くにはどうするのっとくらぁ!

by 1031no
♥0 | Line 31 | Modified 2010-03-05 23:41:24 | MIT License
play

ActionScript3 source code

/**
 * Copyright 1031no ( http://wonderfl.net/user/1031no )
 * MIT License ( http://www.opensource.org/licenses/mit-license.php )
 * Downloaded from: http://wonderfl.net/c/iTYC
 */

// forked from sdkfz181tiger's 別のクラス複数置くにはどうするのっとくらぁ!
//別のクラス複数置くにはどうするのっとくらぁ!
//メインクラス
package{
	import flash.events.Event;
	import flash.events.MouseEvent;
	import flash.display.Sprite;
	
	public class Index extends Sprite{
		private var _rara:Rara;
		
		public function Index(){
			init();
		}
		private function init():void{
			_rara = new Rara();
			_rara.x = stage.stageWidth/2;
			_rara.y = stage.stageHeight/2;
			addChild(_rara);
		}
	}
}

//Raraクラス
import flash.display.Sprite;
class Rara extends Sprite{
	public var _sprite:Sprite;
	
	public function Rara(){
		init();
	}
	private function init():void{
		_sprite = new Sprite();
		_sprite.graphics.beginFill(0x772255);
		_sprite.graphics.drawCircle(0,0,30);
		_sprite.graphics.endFill();
		addChild(_sprite);
	}
}