script_enemy_main {

let frame1 = 0;
let frame2 = 0;
let frame3 = 0;
let frame4 = 0;
let frame5 = 0;
let frame6 = 0;
let frame7 = 0;
let frame8 = 0;
let frame9 = 0;
let frame10 = 0;
let frame11 = 0;
let anim1 = 0;
let anim2 = 0;
let anim3 = 0;
let a1 = 0;
let a2 = 0;
let a3 = 0;
let a4 = 0;
let a5 = 0;
let a6 = 0;
let a7 = 0;
let a8 = 0;
let acc1 = 0;
let acc2 = 0;
let acc3 = 0;
let acc4 = 0;
let acc5 = 0;
let acc6 = 0;
let acc7 = 0;
let acc8 = 0;
let acc9 = 0;
let acc10 = 0;
let acc11 = 0;
let acc12 = 0;
let kospin = 0;


let ST1 = "script\WWW\Worldwide War\Stage1\mu\bgm.mp3";
   let BO1  = GetCurrentScriptDirectory~"mu\bgm.ogg";
	 

let SP = GetCurrentScriptDirectory~"sprites\futo.png";
let Custom = GetCurrentScriptDirectory~"sup\supershot.txt";
let MC = GetCurrentScriptDirectory~"sprites\NMC.png";
let CBG1 = GetCurrentScriptDirectory~"ef\cbg1.png";
let CBG2 = GetCurrentScriptDirectory~"ef\cbg2.png";
let NBG1 = GetCurrentScriptDirectory~"ef\nbg1.png";
let charge = GetCurrentScriptDirectory~"se\Charge2.wav";
let sh1 = GetCurrentScriptDirectory~"se\Shot1.wav";
let sh2 = GetCurrentScriptDirectory~"se\BulletWave.wav";
let Cut = GetCurrentScriptDirectory~"ef\PlCut.png";
let Cut2 = GetCurrentScriptDirectory~"ef\EnCut.png";

    @Initialize {
SetY(-1000);
LoadUserShotData(Custom);
LoadGraphic(SP);
LoadGraphic(MC);
LoadGraphic(Cut);
LoadGraphic(Cut2);
LoadGraphic(CBG1);
LoadGraphic(CBG2);
LoadGraphic(NBG1);
LoadSE(charge);
LoadSE(sh1);
LoadSE(sh2);
LoadMusic(BO1);
CreateEventFromScript("EVENT1");
SetLife(1);
    }

    @MainLoop {
		if(GetEventStep== 1){
			SetLife(0);
		}
yield;
    }

    @DrawLoop {
SetTexture(MC);
SetRenderState(ADD);
SetGraphicAngle(0,0,-acc1);
SetGraphicScale(2+acc3,2+acc3);
SetGraphicRect(0, 0, 128, 128);
SetAlpha(255);
SetColor(255,255,255);
DrawGraphic(GetX, GetY);

SetTexture(SP);
SetRenderState(ALPHA);
SetGraphicAngle(0,0,0);
SetGraphicScale(1,1);
SetGraphicRect(0, 0, 52, 86);
SetAlpha(255);
DrawGraphic(GetX, GetY+3*sin(anim1));

acc1 += 8;
acc2 += 2;
anim1 += 7;
anim2 += 0.4;
anim3++;
acc5 += 2;
acc3 = 0.3*cos(acc2);
 }
    @Finalize {
    }
}

script_event EVENT1{

let Cut = GetCurrentScriptDirectory~"event\PlCut.png";
let Cut2 = GetCurrentScriptDirectory~"event\EnCut.png";
let Cut3 = GetCurrentScriptDirectory~"event\EnCut2.png";
let Cut4 = GetCurrentScriptDirectory~"event\EnCut3.png";

@Initialize{
LoadGraphic(Cut);
LoadGraphic(Cut2);
LoadGraphic(Cut3);
LoadGraphic(Cut4);
 }

@MainLoop{              
SetGraphicRect(LEFT, 0, 0, 220, 300);                     
MoveChar(LEFT, FRONT);                          
TextOutA("\c[RED]That was...easy."); 
TextOutA("\c[GREEN]Yeah, she didn't put up much of a\nfight.");      
TextOutA("\c[RED]Hey, look! Something is ahead!");        
SetStep(1);
End;           //This ends the event.
}

 @Finalize{
 }
}
}