Тема: dispatchEvent
Показать сообщение отдельно
Старый 19.08.2007, 23:57
tov_diatel вне форума Посмотреть профиль Отправить личное сообщение для tov_diatel Найти все сообщения от tov_diatel
  № 12  
Ответить с цитированием
tov_diatel

Регистрация: Dec 2005
Сообщений: 113
Прости. Я очень плохо разбираюсь.
Вот сделал:
Код:
 public function Arrow() { 
               	addEventListener(Event.ENTER_FRAME, Update); 
				addEventListener(Event.ADDED, Random );
           } 
           private function Random() {
			  	 flag=0;
				 x=0;
				 y=0;
				 lemx=parent.width;
				 lemy=parent.height;
				 xs=Math.random()*5;
				 ys=Math.random()*5;	
				
			   }
теперь ошибки такие:
ArgumentError: Error #1063: Argument count mismatch on main::Arrow/::Random(). Expected 0, got 1.
at flash.display::Sprite/flash.display:Sprite::constructChildren()
at flash.display::Sprite$iinit()
at main::Main$iinit()
at flash.display::Sprite/flash.display:Sprite::constructChildren()
at flash.display::Sprite$iinit()
at flash.display::MovieClip$iinit()
at test_fla::MainTimeline$iinit()
ArgumentError: Error #1063: Argument count mismatch on main::Arrow/::Random(). Expected 0, got 1.
at flash.display:isplayObjectContainer/addChild()
at main::Text$iinit()
at flash.display::Sprite/flash.display:Sprite::constructChildren()
at flash.display::Sprite$iinit()
at flash.display::MovieClip$iinit()
at test_fla::MainTimeline$iinit()