

script_enemy_main
{    

    let imgEnemy="script\DanMUku\Stage2\Image\WaruigiN.png";
    let z = 0;
    let w = 0.5;
   @Initialize
   {

      LoadGraphic(imgEnemy);
            SetLife(1);
            SetEnemyMarker(true);
            SetInvincibility(150);
            SetMovePosition02(GetCenterX, GetCenterY - 100, 120);
            CreateEventFromScript("name");
   }
   
   @MainLoop
   {
	if (!OnEvent) {
		AddLife(-1);
	}
   }
   @Finalize
   {
      DeleteGraphic(imgEnemy);
   }
   
   @DrawLoop
   {
            SetColor(255,255,255);
            SetRenderState(ALPHA);
            SetTexture(imgEnemy);
            SetGraphicRect(0,0,40,40);
            DrawGraphic(GetX,GetY+z);
     if(z==10){w=-0.5;}
     if(z==-10){w=0.5;}
z+=w;
	DrawText("War'", GetClipMinX+10, GetClipMinY+15, 12, 255);
   }

}

script_event name{

@Initialize{
  LoadGraphic("script\DanMUku\Joueur\KorA\Kordialogue.png");
  LoadGraphic("script\DanMUku\Stage2\Image\Warcutin.png");
 }

@MainLoop{
 SetChar(LEFT, "script\DanMUku\Joueur\KorA\Kordialogue.png");                    
SetGraphicRect(LEFT, 0, 0, 121, 214);           
MoveChar(LEFT, BACK);
SetChar(RIGHT, "script\DanMUku\Stage2\Image\Warcutin.png");
SetGraphicRect(RIGHT, 0, 0, 121, 214);   
MoveChar(RIGHT, FRONT);
TextOutA("\c[RED] Is there anything I can do?");
MoveChar(RIGHT, BACK);
MoveChar(LEFT, FRONT);
TextOutA("\c[BLUE] You could tell me \n where to find the responsibles.");
MoveChar(LEFT, BACK);
MoveChar(RIGHT, FRONT);
TextOutA("\c[RED] I don't know... \n But Luidi told me he found them.");
MoveChar(RIGHT, BACK);
MoveChar(LEFT, FRONT);
TextOutA("\c[BLUE] Alright, I just have to find HIM, then.");
End;
}

 @Finalize{
  DeleteGraphic("player\korHosik\Kordialogue.png");
  DeleteGraphic("script\DanMUku\Stage1\Image\Warcutin.png");
 }
}
