script_enemy_main{
	#include_function"script\Yui\CharacterRect.txt"
let boss = "script\Yui\Img\yui.png";


	@Initialize{
		SetLife( 1 );
		DeleteEnemyShotToItem( ALL );
		CollectItems;
		SetDamageRate( 0, 0 );
		CreateEventFromScript( "talk" );

		LoadGraphic(imgBoss);
	}
	@MainLoop{
		if(!OnEvent()){AddLife(-GetLife);}
		yield;
		SetMovePosition02(GetCenterX, GetClipMinX+120, 1);
	}
	@DrawLoop{
	if(GetSpeedX()<0){SetGraphicRect(GraphicRectLeft[0],GraphicRectLeft[1],GraphicRectLeft[2],GraphicRectLeft[3]);}
	else if(GetSpeedX()>0){SetGraphicRect(GraphicRectRight[0],GraphicRectRight[1],GraphicRectRight[2],GraphicRectRight[3]);}
	else {SetGraphicRect(GraphicRectCenter[0],GraphicRectCenter[1],GraphicRectCenter[2],GraphicRectCenter[3]);}
	SetAlpha(255);
	SetGraphicExpansion(GraphicScale,GraphicScale);
	SetColor(255,255,255);
	SetGraphicAngle(0,0,0);
	SetTexture(imgBoss);	
	DrawGraphic(GetX(),GetY());
}

	@Finalize{
	}
}





script_event talk{
let Yui = GetCurrentScriptDirectory~"Img\talk\talk.png";
let angry = GetCurrentScriptDirectory~"Img\talk\angry.png";
let normal = GetCurrentScriptDirectory~"Img\talk\Marisa.png";
let oh = GetCurrentScriptDirectory~"Img\talk\Marisa9.png";
let eh = GetCurrentScriptDirectory~"Img\talk\Marisa8.png";
let happy = GetCurrentScriptDirectory~"Img\talk\Marisa3.png";
let uu = GetCurrentScriptDirectory~"Img\talk\Marisa6.png";
let seria = GetCurrentScriptDirectory~"Img\talk\Marisa4.png";

	
@Initialize{
LoadGraphic(Yui);
LoadGraphic(angry);
LoadGraphic(normal);
LoadGraphic(happy);
LoadGraphic(eh);
LoadGraphic(oh);
LoadGraphic(seria);
LoadGraphic(uu);
}

@MainLoop{
SetChar(RIGHT, angry);
SetGraphicRect(RIGHT, 0, 0, 192, 320);
MoveChar(RIGHT, FRONT);
TextOutA("\c[WHITE]Espera!");
MoveChar(RIGHT, BACK);
SetChar(LEFT, oh);
SetGraphicRect(LEFT, 0, 0, 192, 320);
MoveChar(LEFT, FRONT);
TextOutA("\c[YELLOW]Ah??");
MoveChar(LEFT, BACK);


SetChar(RIGHT, angry);
SetGraphicRect(RIGHT, 0, 0, 192, 320);
MoveChar(RIGHT, FRONT);
TextOutA("\c[WHITE]Que aun no me voy!");
SetChar(RIGHT, Yui);
TextOutA("\c[WHITE]Quisiera hacer algo antes de irme.");
MoveChar(RIGHT, BACK);

SetChar(LEFT, normal);
SetGraphicRect(LEFT, 0, 0, 192, 320);
MoveChar(LEFT, FRONT);
TextOutA("\c[YELLOW]???????");
MoveChar(LEFT, BACK);

SetChar(RIGHT, Yui);
SetGraphicRect(RIGHT, 0, 0, 192, 320);
MoveChar(RIGHT, FRONT);
TextOutA("\c[WHITE]Ahora SI comprenderas que no soy un \ngato ordinario");
TextOutA("\c[WHITE]fufu");

DeleteMusic(GetCurrentScriptDirectory ~ "tewi.mp3");
PlayMusic(GetCurrentScriptDirectory ~ "chen.mp3");

 End;
 }

@Finalize{
DeleteGraphic(Yui);
DeleteGraphic(angry);
DeleteGraphic(normal);
DeleteGraphic(happy);
DeleteGraphic(eh);
DeleteGraphic(oh);
DeleteGraphic(seria);
DeleteGraphic(uu);
 }
}