
	#Title[zako1]
	#Text[zako]
	#ScriptVersion[2]
	
	script_enemy_main
	{
        let img = "script\ƒUƒR\zako3.PNG";
        let frame = 0;

      LoadCommonData;
		@Initialize
		{ 
              SetLife(250);

              LoadGraphic(img);
              SetTexture(img);  SetGraphicRect(0, 0, 64, 64);
             TMain;
		
		}
			
		@MainLoop
		{
              SetScore(125+125*GetPlayerLife);
    SetCollisionA(GetX, GetY, 24);
    SetCollisionB(GetX, GetY, 24);
   yield;


		}
		
		@DrawLoop
		{
		   DrawGraphic(GetX, GetY);
		}
			
		@Finalize
		{

		}
         task TMain{
               yield;
		CreateEnemyFromFile("script\–^ƒ^ƒR\TAKOZAKO08.TXT",GetX,GetY,0,0,0);
                   move;
  loop(60){ yield; }
                    shot;
                    

                   }
         task move{ let x =rand(64, 384);
                   let y =rand(240, 48);
loop{
     SetMovePosition02(GetEnemyX, GetEnemyY,60);
        loop(1) { yield; }}
                  }
         task shot{  loop{ let a=rand(10,90);  
let AA=GetAngleToPlayer-30;
loop(5){


CreateShotA(11,GetX,GetY,0);
SetShotDataA(11,0,4,AA,0,0,9,BLUE21);
FireShot(11);
AA=AA+10;
 
        }
        loop(60) { yield; } 
                 }}
        sub nige{ 
              SetMovePosition02(GetX, GetClipMaxY, 180);
        loop(180) { yield; } 
             VanishEnemy;
                }
	}
  
