script_enemy_main {
	let bossImage = GetCurrentScriptDirectory~"cirno.png";
	let bossBack = GetCurrentScriptDirectory~"cirnoback.png";
	@Initialize {
		if(GetPlayerType==USER_PLAYER) { RaiseError("Why are you using this player","Error"); }
		SetLife(4000);
		SetDamageRate(100, 50);
		SetTimer(35);
		LoadGraphic(bossImage);
		LoadGraphic(bossBack);
	}
	let frame = -120;
	let frame2 = -120;
	let frameMove = -120;
	let angle = 0;
	@MainLoop {
		SetCollisionA(GetX, GetY, 50);
		SetCollisionB(GetX, GetY, 50);
		if(frame == -120) {
			SetMovePosition02(GetCenterX, GetCenterY/2, 15);
			Concentration01(120);
		}
		frame++;
		frame2++;
		frameMove++;
		if(frame >= 45) {
			loop(3) { CreateLaser01(GetX, GetY, 8+rand(-3,3), GetAngleToPlayer+rand(-30,30), 350, 25, WHITE03, 10); }
			frame = 0;
		}
		if(frame2 >= 3) {
			let tempangle = 0;
			loop(6) { CreateShot01(GetX, GetY, rand(2,4), tempangle+angle, BLUE04, 10); tempangle+=360/6; }
			angle += 3; while(angle >= 360) { angle-=360; }
			frame2 = 0;
		}
		if(frameMove >= 150) {
			SetMovePosition02(GetCenterX+rand(-150, 150), GetCenterY/2+rand(-100, 100), 60);
		frameMove = 0; }
	}
	@DrawLoop {
		SetTexture(bossImage);
		SetGraphicRect(0, 0, 128, 128);
		SetGraphicScale(1, 1);
		SetGraphicAngle(0, 0, 0);
		SetAlpha(255);
		DrawGraphic(GetX, GetY);
		DrawText("Cirno", 40, 30, 12, 255);
	}
	let backspin = 0;
	@BackGround {
		SetTexture(bossBack);
		SetGraphicRect(0, 0, 512, 512);
		SetGraphicScale(3/2, 3/2);
		SetGraphicAngle(0, 0, backspin);
		SetAlpha(255);
		DrawGraphic(GetCenterX, GetCenterY);
		backspin+=1; backspin%=360;
	}
	@Finalize {
		DeleteGraphic(bossImage);
		DeleteGraphic(bossBack);
	}
}