#TouhouDanmakufu
#Title[TEST THIS]
#Text[]
#Image[]
#Player[REIMU,MARISA]
#ScriptVersion[2]
script_enemy_main{
	


let lol = 0;
	#include_function ".\Boss.txt";
	
	@Initialize{
		
		Init(8000,5,"Momiji Inubashiri");		
		BossInit(true,34,0,false,[255,255,255],[255,64,64]);
		SetInvincibility(100);
		SetDamageRate(200,200);
		mainTask;
		SetMovePosition03(GetCenterX,GetCenterY-120,10,5);
		LoadUserShotData(CSD~"supershot.txt");
		//SetEnemyMarker(true);
		
		
	}
	
	@MainLoop{
	SetCollisionA(GetX,GetY,32);
	
		SetCollisionB(GetX,GetY,16);
		SPMainLoop;
		

		

		yield;
		
	}
	task DrawTask{
		Momizi;
	}
	
	task mainTask{
		fire;
		
	}
	task SPFinalize{
		CreateEnemyFromFile(CSD~"spell6.txt",GetX,GetY,0,0,0);
			
		
		CreateMOFItem("BOMB_F",GetX,GetY);
		
		
	}
	task fire{
		wait(100);	
		loop{
			let r = rand(0,360);
			PlaySEEx(CSD~"se\lazer01.wav");
			ascent(i in 0..25){
			CreateLaser01(GetX,GetY,10,360/25*i+GetAngleToPlayer,1000,13,WHITE01,10);
			
			}
			SetMovePosition03(GetPlayerX+rand_int(-50,50),GetCenterY-100+rand(-20,20),10,7);
			wait(60);
			
		}

	}

}