#include "..\C-Engine\CHeader.hpp" #include"BoatControl.hpp" #include"BoatControlPerso.hpp" #include"BoatControlPirate.hpp" #include"EngineGUI.hpp" int Intro();//Intro du jeu int Menu();//Menu du jeu int Jeu( int stage);// Jeu en lui meme int HistoireStage1();// Les différentes histoires. int HistoireStage2(); int HistoireStage3(); void PrintTextDelay( int x , int y , int delay , char * txt , int length)//Fonction qui affiche le text en plus classe. { int i; char * buffer = (char *)malloc(sizeof(char) * 2); for(i = 0; i < length ; i++) { input_update(); if(input_trigger(K_SHIFT))return ; buffer[0] = txt[i]; buffer[1] = '\0'; PrintMini( x + i*4 , y ,(const unsigned char *) buffer, 0); ML_display_vram(); Sleep(delay); } } int Intro() { const unsigned char Bateau[]={0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 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8, 0x0, 0x21, 0x0, 0xc0, 0x0, 0x0, 0x1, 0x80, 0x0, 0x0, 0x0, 0x1, 0x0, 0x3f, 0xff, 0xf8, 0x0, 0x51, 0x0, 0xc0, 0x0, 0x0, 0x1, 0x80, 0x0, 0x0, 0x0, 0x0, 0x0, 0x7f, 0xff, 0xfc, 0x0, 0x21, 0x0, 0xc0, 0x0, 0x0, 0x1, 0x80, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xfe, 0x0, 0x1, 0x1, 0x80, 0x0, 0x0, 0x3, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0xff, 0xff, 0xff, 0x80, 0x0, 0x81, 0x80, 0x0, 0x0, 0x3, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf, 0xff, 0xff, 0xff, 0xf8, 0x0, 0x81, 0x80, 0x0, 0x0, 0x3, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xff, 0xfe, 0x0, 0x81, 0x80, 0x0, 0x0, 0x3, 0x0, 0x0, 0x0, 0x0, 0x7f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf7, 0xff, 0xff, 0xff, 0xf7, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf7, 0xff, 0xff, 0xff, 0xf7, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, }; const unsigned char BateauN[]={0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x1c, 0x0, 0x3, 0x0, 0x1c, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x7f, 0x0, 0x3, 0x0, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x7f, 0x0, 0x3, 0x0, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x3, 0xc0, 0x7f, 0x0, 0x7, 0x80, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x7f, 0x0, 0x3, 0x0, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x7f, 0x0, 0x3, 0x0, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x7f, 0x0, 0x3, 0x0, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x7f, 0x0, 0x3, 0x0, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x7f, 0x0, 0x3, 0x0, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0, 0x0, 0x1, 0x0, 0x1f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf0, 0x0, 0x1, 0x0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfe, 0x0, 0x1, 0x1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0, 0x1, 0x7, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x80, 0x1, 0x7, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xc0, 0x1, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xe0, 0x1, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf0, 0x1, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf8, 0x1, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfc, 0x1, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfe, 0x1, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x81, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xc1, 0x7f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xc1, 0x7f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xe1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xe1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf9, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf9, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf9, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf9, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xe1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xe1, 0x7f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xc1, 0x7f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xc1, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x81, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfe, 0x1, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfc, 0x1, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf8, 0x1, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf0, 0x1, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xe0, 0x1, 0xf, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xc0, 0x1, 0x7, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x80, 0x1, 0x3, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0, 0x1, 0x1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfe, 0x0, 0x1, 0x0, 0x7f, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xf0, 0x0, 0x1, 0x0, 0x7, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0, 0x0, 0x1, 0x0, 0x1, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x80, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x7f, 0x0, 0x3, 0x0, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x7f, 0x0, 0x3, 0x0, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x7f, 0x0, 0x3, 0x0, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x7f, 0x0, 0x3, 0x0, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x7f, 0x0, 0x3, 0x0, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x3, 0xc0, 0x7f, 0x0, 0x7, 0x80, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x7f, 0x0, 0x3, 0x0, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x7f, 0x0, 0x3, 0x0, 0x7f, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x1, 0x80, 0x1c, 0x0, 0x3, 0x0, 0x1c, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, }; for(int i=0 ; i < 258 ; i++) { ML_clear_vram(); if( i > 124) { PrintXY( 4 , 15 , "L'invasion Seanchans" , 0); PrintMini(50 , 30 , "Par Fife86" , 0); PrintMini(0 , 40 , "Cree a l'occasion des 7 Days CPC" , 0); } if(i < 150) { ML_rectangle(90,10,127,50,1,ML_WHITE , ML_WHITE); } ML_bmp_or_cl(BateauN , i - 127 , 0 , 127 , 63); ML_bmp_and_cl(Bateau , i - 127 , 0 , 127 , 63); Sleep(20); ML_display_vram(); } Sleep(1000); return 1; } int Menu() { bool end = false; int choix = 0; int cx = 40; int cy = 20; const unsigned char Curseur[]={0x9f, 0xdf, 0xff, 0xff, 0xff, 0xdf, 0x9f, }; const unsigned char CurseurM[]={0xbf, 0xff, 0xff, 0xbf, }; Intro(); while(end == false) { ML_clear_vram(); input_update(); PrintXY( 4 , 5 , "L'invasion Seanhans" , 0); PrintXY(45,20,"Stage 1" , 0); PrintXY(45,32,"Stage 2" , 0); PrintXY(45,44,"Stage 3" , 0); PrintMini(53,57,"Quitter" , 0); const unsigned char Deco[]={0x0,0xd0,0x0,0x0,0x30,0x0,0x0,0x10,0x0,0x0,0x10,0x0,0x0,0x10,0x0,0x4,0x71,0x0,0x4,0xf8,0x80,0x4,0xfb,0x80,0x1d,0xfb,0x80,0x3e,0x17,0xc4,0x3e,0x7f,0xcc,0x7e,0xf0,0x9e,0x5,0xff,0xbe,0x1d,0xfb,0xff,0x3e,0x71,0xff,0x7c,0x10,0xff,0x4,0xff,0xfe,0x1f,0x7e,0xf8,0x8e,0x38,0xc0,0x44,0x10,0x8e,0x24,0x11,0xfe,0x14,0xff,0xfe,0xf,0xff,0xfc,0x7,0xff,0xf8}; ML_bmp_or(Deco ,8,30,24,24); ML_bmp_or(Deco ,95,30,24,24); if(input_any_key()) { if(input_trigger(K_DOWN))choix ++; if(input_trigger(K_UP))choix --; if(choix < 0)choix = 0; if(choix > 3)choix = 3; switch(choix) { case 0: cx = 40; cy = 20; break; case 1: cx = 40; cy = 32; break; case 2: cx = 40; cy = 44; break; case 3: cx = 47; cy = 57; break; } if(input_trigger(K_EXE)) { switch(choix) { case 0: Jeu(1); break; case 1: Jeu(2); break; case 2: Jeu(3); break; case 3: end = true; break; } } } if(choix != 3) { ML_bmp_or(Curseur , cx , cy , 3 , 7); ML_bmp_or_rotate(Curseur , cx + 49 , cy , 3 , 7 , 180); } else { ML_bmp_or(CurseurM , cx , cy , 2 , 4); ML_bmp_or_rotate(CurseurM , cx + 37 , cy -1 , 2 , 4 , 180); } ML_display_vram(); } return 1; } int HistoireStage1() { ML_clear_vram(); ML_rectangle(30,20,97,35,1,ML_BLACK,ML_WHITE); PrintXY(45,23, "Stage 1" , 0); ML_display_vram(); Sleep(2000); ML_clear_vram(); PrintMini(80,58,"Skip : SHIFT",0); PrintTextDelay(15,10,100,"Bienvenue Capitaine,", 20); if(input_trigger(K_SHIFT) == false)Sleep(500); if(input_trigger(K_SHIFT) == false)PrintTextDelay(15,20,100,"Le Dragon Reincarne vient", 25); if(input_trigger(K_SHIFT) == false)PrintTextDelay(15,30,100,"de vous envoyer un message.", 27); if(input_trigger(K_SHIFT) == false)Sleep(1000); ML_clear_vram(); PrintMini(80,58,"Skip : SHIFT",0); PrintTextDelay(15,10,100,"Votre mission est de", 20); if(input_trigger(K_SHIFT) == false)PrintTextDelay(15,20,100,"detruire des eclaireurs", 23); if(input_trigger(K_SHIFT) == false)PrintTextDelay(15,30,100,"Seanchans.", 10); if(input_trigger(K_SHIFT) == false)Sleep(1000); ML_clear_vram(); PrintMini(80,58,"Skip : SHIFT",0); PrintTextDelay(15,10,100,"Ils sont aux nombres de 3.", 26); if(input_trigger(K_SHIFT) == false)PrintTextDelay(15,20,100,"Le Seigneur Dragon compte", 25); if(input_trigger(K_SHIFT) == false)PrintTextDelay(15,30,100,"sur vous.", 9); if(input_trigger(K_SHIFT) == false)Sleep(1000); ML_clear_vram(); PrintTextDelay(30,28,100,"Bonne chance", 13); Sleep(2000); return 1; } int HistoireStage2() { ML_clear_vram(); ML_rectangle(30,20,97,35,1,ML_BLACK,ML_WHITE); PrintXY(45,23, "Stage 2" , 0); ML_display_vram(); Sleep(2000); ML_clear_vram(); PrintMini(80,58,"Skip : SHIFT",0); PrintTextDelay(5,10,100,"Chef, nos cotes sont attaquees", 30); if(input_trigger(K_SHIFT) == false)Sleep(500); if(input_trigger(K_SHIFT) == false)PrintTextDelay(10,20,100,"Il faut defendre nos terres", 27); if(input_trigger(K_SHIFT) == false)PrintTextDelay(10,30,100,"contre les Seanchans.", 21); if(input_trigger(K_SHIFT) == false)Sleep(500); if(input_trigger(K_SHIFT) == false)PrintTextDelay(15,40,100,"Ils y a 6 envahisseurs.", 23); if(input_trigger(K_SHIFT) == false)Sleep(1000); return 1; } int HistoireStage3() { ML_clear_vram(); ML_rectangle(30,20,97,35,1,ML_BLACK,ML_WHITE); PrintXY(45,23, "Stage 3" , 0); ML_display_vram(); Sleep(2000); ML_clear_vram(); PrintMini(80,58,"Skip : SHIFT",0); PrintTextDelay(5,10,100,"C est la derniere bataille", 26); if(input_trigger(K_SHIFT) == false)Sleep(500); if(input_trigger(K_SHIFT) == false)PrintTextDelay(10,20,100,"Ils ont perdus, il ne reste", 27); if(input_trigger(K_SHIFT) == false)PrintTextDelay(10,30,100,"qu'une dizaine de bateaux", 25); if(input_trigger(K_SHIFT) == false)Sleep(500); if(input_trigger(K_SHIFT) == false)PrintTextDelay(15,40,100,"a couler. Tenez bon.", 20); if(input_trigger(K_SHIFT) == false)Sleep(1000); return 1; } int Jeu( int stage) { // Les différents sprites utilisé. const unsigned char Grade1[]={0x1,0xc0,0x0,0x2,0x20,0x0,0x4,0x10,0x0,0x8,0x88,0x0,0x9,0x48,0x0,0x8,0x8,0x0,0x38,0xe,0x0,0x38,0x8e,0x0,0x9,0xc8,0x0,0x8,0x8,0x0,0x8,0x8,0x0,0x8,0x88,0x0,0x1f,0x7c,0x0,0x3c,0x9e,0x0,0x8,0x8,0x0,0xc,0x18,0x0,0x7,0xf0,0x0}; const unsigned char Grade2[]={0x1,0xc0,0x0,0x2,0x20,0x0,0x4,0x10,0x0,0x8,0x88,0x0,0x9,0x48,0x0,0xa,0x28,0x0,0x38,0xe,0x0,0x38,0xe,0x0,0x8,0x88,0x0,0x39,0xce,0x0,0x38,0xe,0x0,0x8,0x88,0x0,0x1f,0x7c,0x0,0x3c,0x9e,0x0,0x8,0x8,0x0,0xc,0x18,0x0,0x7,0xf0,0x0}; const unsigned char Grade3[]={0x1,0xc0,0x0,0x2,0x20,0x0,0x4,0x90,0x0,0x9,0x48,0x0,0x8,0x8,0x0,0x38,0xe,0x0,0x38,0xe,0x0,0x8,0x88,0x0,0x1f,0x7c,0x0,0x3c,0x9e,0x0,0x8,0x8,0x0,0x8,0x88,0x0,0x1f,0x7c,0x0,0x3c,0x9e,0x0,0x8,0x8,0x0,0xd,0x58,0x0,0x7,0xf0,0x0}; const unsigned char Grade4[]={0x1,0xc0,0x0,0x1a,0x2c,0x0,0x1c,0x9c,0x0,0x9,0x48,0x0,0xa,0xa8,0x0,0x38,0xe,0x0,0x38,0xe,0x0,0x8,0x88,0x0,0x1f,0x7c,0x0,0x3c,0x9e,0x0,0x8,0x8,0x0,0x8,0x88,0x0,0x1f,0x7c,0x0,0x3c,0x9e,0x0,0x8,0x8,0x0,0xd,0x58,0x0,0x7,0xf0,0x0}; const unsigned char Grade5[]={0x0,0x70,0x0,0x0,0x88,0x0,0xd,0x5,0x80,0xe,0x23,0x80,0x4,0xf9,0x0,0x5,0x25,0x0,0x1c,0x51,0xc0,0x1c,0x1,0xc0,0x4,0x21,0x0,0xf,0xdf,0x80,0x1e,0x23,0xc0,0x4,0x1,0x0,0x4,0x1,0x0,0x1c,0x71,0xc0,0x1c,0x1,0xc0,0x4,0x21,0x0,0xf,0xdf,0x80,0x1e,0x23,0xc0,0x4,0x1,0x0,0x6,0xdb,0x0,0x3,0xfe,0x0}; Sprite Sprite_Bateau_Grade1( Grade1 , 17 , 17 ); Sprite_Bateau_Grade1.CreateReverse(); Sprite Sprite_Bateau_Grade2( Grade2 , 17 , 17 ); Sprite_Bateau_Grade2.CreateReverse(); Sprite Sprite_Bateau_Grade3( Grade3 , 17 , 17 ); Sprite_Bateau_Grade3.CreateReverse(); Sprite Sprite_Bateau_Grade4( Grade4 , 17 , 17 ); Sprite_Bateau_Grade4.CreateReverse(); Sprite Sprite_Bateau_Grade5( Grade5 , 21 , 21 ); Sprite_Bateau_Grade5.CreateReverse(); Animation A_Bateau_Grade1( Sprite_Bateau_Grade1); Animation A_Bateau_Grade2( Sprite_Bateau_Grade2); Animation A_Bateau_Grade3( Sprite_Bateau_Grade3); Animation A_Bateau_Grade4( Sprite_Bateau_Grade4); Animation A_Bateau_Grade5( Sprite_Bateau_Grade5); const unsigned char I_Boulet[]={ 0xff , 0xff}; Sprite Sprite_Boulet( I_Boulet , 2 ,2); Animation A_Boulet( Sprite_Boulet); const unsigned char TileSetMer[]={0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x1,0xf0,0x7f,0x0,0x40,0x0,0x70,0x0,0x10,0x0,0x30,0x0,0x60,0x0,0x40,0x0,0x40,0x0,0x40,0x0,0x80,0x0,0x80,0x0,0xf0,0x0,0x10,0x0,0x1f,0x80,0x0,0x80,0x0,0x80,0x0,0xc0,0x0,0x40,0x0,0x40,0x0,0x60,0x0,0x20,0x0,0x20,0x0,0x30,0x0,0x10,0x0,0x10,0x0,0x30,0x0,0x20,0x0,0x60,0x0,0x40,0x7,0x40,0x5,0xc0,0x4,0xc0,0x3c,0xc0,0x20,0x0,0xc0,0x0,0x80,0x0,0x80,0x0,0xc0,0x0,0x60,0x0,0x20,0x0,0x20,0x0,0x30,0x0,0xe,0x0,0x3,0xc0,0x0,0x60,0x0,0x20,0x0,0x30,0xc1,0xf0,0x7b,0x0,0x6,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x0,0x2,0x0,0x7f,0x10,0xc1,0xe0}; bool TileProp[]= { false , true , true, true, true, true, true}; //, true , true , true , true , true , true , true , true , true , true , true , true , true , true, true , true , true , true , true , true , true , true }; const unsigned char * map1[]={ "0000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000520000000000000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000030000000000000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000", "0000000000000000000000000000000000120000000000000012000000000000000000000052000000000000000000000000", "0000001200000000000000000000000000430000000000000040200000000000000000000000200000000000000000000000", "0000004300000000000000000000000000000000000000000010020000000000000000000000100000000000000000000000", "0000000000000000000000000000000000000000000000000300004000000000000000000001000000000000000000000000", "0000000000000000000000000000000000000000000000000400000460000000000000000030000000000000000000000000", "0000000000000000000000000000000000000000000000000020000304000000000000000100000000000000000000000000", "0000000000000000001200000000000000000000000000000034000000200000000000000400000000000000000000000000", "0000000000000000002040000000000000000000000000000300000000100000000000000040000000000000000000000000", "0000000000000000000230000000000000000000000000003000000003000000000000000002000000000000000000000000", "0000000000000000000000000000000000000000000000002000000010000000000000000000200000000000000000000000", "0000000000000000000000000000000000000000000000000400000300000000000000000000100000000000000000000000", "0000000000000000000000000000000000000000000000000020001000000000000000000003000000000000000000000000", "0000000000000000000000000000000000000000000000000004034000000000000000000005200600000000000000000000", "0000000000000000000000000000000000000000000000000001060200000000000000000000055020000000000000000000", "0000000000000000000000000000000000000000000000000004104300000000000000000000000030000000000000000000", "0000000000000000000000000000012140600000000000000000000000000000000000000000000100000000000000000000", "0000000000000000000000000000020205300000000000000000000000000000000000000000001000000000000000000000", "0000000000000000000000000000004001000000000000000000000000000000000000000000005200000000000000000000", "0000000000000000000000000000003030000000000000000000000000000000000000000000000300000000000000000000", "0000000000000000000000000000010100000000000000000000000000000000000000000000001000000000000000000000", "0000000000000000000000000000023000000000000000000000000000000000000000000000004000000000000000000000", "0000014000000000000000000000000000000000000000000000000000000000000000000000000520000000000000000000", "0000335000000000000000000000000000000000000000000000000000000000000000000000000002000000000000000000", "0012226000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000", "0040503000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000", "0034010000000000000000000000000000000000000000000000000000001400000000000000000300000000000000000000", "0054020000000000000000000000000000000000000000000000000000002020000000000000001000000000000000000000", "0000210000000000000000000000000000000000000000000000000000343004000000000000004000000000000000000000", "0000000000000000000000000000000000000000000000000000000001000000400000000000000400000000000000000000", "0000000000000000000000000000000000000000000000000000340030000003500000000000000020000000000000000000", "0000000000000000000000000000000000000000000000000000202100000004000000000000000002000000000000000000", "0000000000000000000000000000000000000000000000000000100000000015000000000000000001000000000000000000", "0000000000000000000000000000000000000000000000000000400000000020000000000000000030000000000000000000", "0000000000000000000000000000000000000000000000000000020000000030000000000000000052006000000000000000", "0000000000000000000000000000000000000000000000000000010000003440000000000000000000550200000000000000", "0000000000000000000000000000000000000000000000000000052143210050000000000000000000000300000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000000001552003000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000000010000430000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000000520000000000000000000000", "0000000000000000000000000000000000006000000000000000000000000000000000000000030000000000000000000000", "0000000000000000000000000000000000630200000000000000000000000000000000000000100000000000000000000000", "0000000606000000000000000000000003000300000000000000000000000000000000000000403552000000000000000000", "0000001054260000000000000000000002601000000000000000000000000000000000000000050000414000000000000000", "0000030000005200000000000000000001030000000000000000000000000000000000000000000000000200000000000000", "0000020000000120000000000000000030041200000000000000000000000000000000000000000000000046060000000000", "0000030000000010000000000000000021400300000000000000000000000000000000000000000000000000502000000000", "0001500003520300000000000000000000023000000000000000000000000000000000000000000000000000000400000000", "0004000002005000000000000000000000000000000000000000000000000000000000000000000000000000000020000000", "0000200000400000000000000000000000000000000000000000000000000000000000000000000000000000000004000000", "0000054000020001400000000000000000000000000000000000000000000000000000000000000000000060000003000000", "0000003000004350020000000000000000000000000000000000000000000000000000000000000340663504120010000000", "0000002000000000030000000000000000000000000000000000000000000000000000000000000205000000005500000000", "0000000460000001500000000000000000000000000000000000000000000000000000000000000100000000000000000000", "0000000005200030000000000000000000000000000000000000000000000000000000000000003000000000000000000000", "0000000000040300000000000000000000000000000000000000000000000000000000000000005200600000000000000000", "0000000000005000000000000000000000000000012000000000000000000000000000000000000055020000000000000000", "0000000000000000000000000000000000000000020400000000000000000000000000000000000000030000000000000000", "0000000000000000000000000000000000000000002300000000000000000000000000000000000000100000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000000000005200000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000000000000300000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000006000000000004000000000000000000", "0000000000000000000000000000000000000000000000000000000000000120001550512000000000520000000000000000", "0000000000000000000000000000000000000000000000000000000000000205550000000200000000002000000000000000", "0000000000000000000000000000000000000000000000000000000000000040000000000020000000001000000000000000", "0000000000000000000000000000000000000001200000000000000000000030000120000030000000010000000000000000", "0000000000000000000000000000000000000010040000000000000000001500001002060300000000300000000000000000", "0000000000000000000000000000000000000020002600000000000000030000004000505000000001000000000000000000", "0000000000000000000000000000000000006010001040000000000000046600000200000000000004000000000000000000", "0000000000000000000000000000000000004500000030000000000000000055400020000000000000400000000000000000", "0000000000000000000000000000000000000200000300000000000000000000020030000000000000020000000000000000", "0000000000000000000000000000000000000100015000000000000000000000004100000000000000002000000000000000", "0000000000000000000000000000000000000460020000000000000000000000000000000000000000001000000000000000", "0000000000000000000000000000000000000002004000000000000000000000000000000000000000030000000000000000", "0000000000000000000000000000000000000001503000000000000000000000000000000000000000100000000000000000", "0000000000000000000000000000000000000004630000000000000000000000000000000000000001000000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000000000005200000000000000000", "0000000000000000000612000000000000000000000000000000000000000000000000000000000000300000000000000000", "0000000000120000000400400000000000000000000000000000000000000000000000000000000001000000000000000000", "0000000000430000000350300000000000000000000000000000000000000000000000000000000004000000000000000000", "0000000000000000000401000000000000000000000000000000000000000000012000000000000000520000000000000000", "0000000000000000000304000000000000000000000000000000000000000000103000000000000000002000000000000000", "0000000000000000001600200000000000000000000000000000000000000000404000000000000000001000000000000000", "0000000000000000005020520000000000000000000000000000000000000000020200000000000000010000000000000000", "0000000000000000000010030000000000000000000000000000000000000000004620000000000000300000000000000000", "0000000000000000000300100000000000000000000000000000000000000000000042000000000001000000000000000000", "0000000000000000000403000000000000000000000000000000000000000000000004460000000004000000000000000000", "0000000000000000000050000000000000000000000000000000000000000000000000210000000000400000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000000000000002000000000000000", "0000000000000000000000000000000000000000000000000000000000000000000000000000000000001000000000000000", }; //*******************Commun*****************// Engine Game;// Création du moteur Vent VentJeu;// Création de la météo. Boat Bateau_Joueur; // Création du bateau du joueur. Object * Bateau = new Object; // Création de l'object Joueur Bateau->GetTransforms()->SetXY(88 * 12,( 100 - 56) * 12);// Placement du joueur sur la map. Bateau->GetRender()->SetRender(A_Bateau_Grade4 );// Affection de l'image du bateau au joueur. Bateau->AddRigibody(); Bateau->GetRigibody()->SetMass(500); Bateau->AffectTag("Bateau"); BoatControlPerso * Bateau_Script = new BoatControlPerso;// Création du script du joueur. Bateau->AffectScript(Bateau_Script); Bateau_Script->Initialisation(& VentJeu , & Bateau_Joueur , & A_Boulet);//Initialisation des pointeurs utilisé dans le script. Map Niveau1;//Création de la map Niveau1.SetMap(TileSetMer , map1 , TileProp , 12 , 12 , 100 ,100);// Paramètrage de la map. Game.AffectMap( &Niveau1);//Affection de la map au moteur. Niveau1.AffectEngine( &Game); EngineGUI Game_GUI;//Création de la GUI. Game.AffectScript(Game_GUI); Game_GUI.Initialisation(& VentJeu , & Bateau_Joueur ); Game.SetFpsWish(26);//Limite des FPS voulut. Game.AddObject( Bateau);//Ajout du joueur au moteur. //***************Stage*************// Boat Bateau_Pirate1;//Création de tout les pirates. Object * Pirate1 = new Object; Pirate1->GetRender()->SetRender(A_Bateau_Grade1 ); BoatControlPirate * Pirate1_Script = new BoatControlPirate; Pirate1->AffectScript(Pirate1_Script); Pirate1_Script->Initialisation(& VentJeu , & Bateau_Pirate1, & A_Boulet); Boat Bateau_Pirate2; Object * Pirate2 = new Object(); Pirate2->GetRender()->SetRender(A_Bateau_Grade1 ); BoatControlPirate * Pirate2_Script = new BoatControlPirate; Pirate2->AffectScript(Pirate2_Script); Pirate2_Script->Initialisation(& VentJeu , & Bateau_Pirate2, & A_Boulet); Boat Bateau_Pirate3; Object * Pirate3 = new Object;; Pirate3->GetRender()->SetRender(A_Bateau_Grade1 ); BoatControlPirate * Pirate3_Script = new BoatControlPirate; Pirate3->AffectScript(Pirate3_Script); Pirate3_Script->Initialisation(& VentJeu , & Bateau_Pirate3, & A_Boulet); Boat Bateau_Pirate4; Object * Pirate4 = new Object;; Pirate4->GetRender()->SetRender(A_Bateau_Grade2 ); BoatControlPirate * Pirate4_Script = new BoatControlPirate; Pirate4->AffectScript(Pirate4_Script); Pirate4_Script->Initialisation(& VentJeu , & Bateau_Pirate4, & A_Boulet); Boat Bateau_Pirate5; Object * Pirate5 = new Object;; Pirate5->GetRender()->SetRender(A_Bateau_Grade2 ); BoatControlPirate * Pirate5_Script = new BoatControlPirate; Pirate5->AffectScript(Pirate5_Script); Pirate5_Script->Initialisation(& VentJeu , & Bateau_Pirate5, & A_Boulet); Boat Bateau_Pirate6; Object * Pirate6 = new Object;; Pirate6->GetRender()->SetRender(A_Bateau_Grade3 ); BoatControlPirate * Pirate6_Script = new BoatControlPirate; Pirate6->AffectScript(Pirate6_Script); Pirate6_Script->Initialisation(& VentJeu , & Bateau_Pirate6, & A_Boulet); Boat Bateau_Pirate7; Object * Pirate7 = new Object;; Pirate7->GetRender()->SetRender(A_Bateau_Grade3 ); BoatControlPirate * Pirate7_Script = new BoatControlPirate; Pirate7->AffectScript(Pirate7_Script); Pirate7_Script->Initialisation(& VentJeu , & Bateau_Pirate7, & A_Boulet); Boat Bateau_Pirate8; Object * Pirate8 = new Object;; Pirate8->GetRender()->SetRender(A_Bateau_Grade3 ); BoatControlPirate * Pirate8_Script = new BoatControlPirate; Pirate8->AffectScript(Pirate8_Script); Pirate8_Script->Initialisation(& VentJeu , & Bateau_Pirate8, & A_Boulet); Boat Bateau_Pirate9; Object * Pirate9 = new Object;; Pirate9->GetRender()->SetRender(A_Bateau_Grade4 ); BoatControlPirate * Pirate9_Script = new BoatControlPirate; Pirate9->AffectScript(Pirate9_Script); Pirate9_Script->Initialisation(& VentJeu , & Bateau_Pirate9, & A_Boulet); switch(stage) { case 1: Pirate1->GetTransforms()->SetXY(50 * 12,( 100 - 54) * 12);//Placement des pirates sur la map. Pirate2->GetTransforms()->SetXY(17 * 12,( 100 - 72) * 12); Pirate3->GetTransforms()->SetXY(16 * 12,( 100 - 34) * 12 ); Game.AddObject( Pirate1);//Ajout des pirates au moteur. Game.AddObject( Pirate2); Game.AddObject( Pirate3); Bateau_Script->objectifmax = 3; HistoireStage1(); break; case 2: Pirate1->GetTransforms()->SetXY(50 * 12,( 100 - 54) * 12); Pirate2->GetTransforms()->SetXY(17 * 12,( 100 - 72) * 12); Pirate3->GetTransforms()->SetXY(16 * 12,( 100 - 34) * 12 ); Pirate4->GetTransforms()->SetXY(30 * 12,( 100 - 20) * 12); Pirate5->GetTransforms()->SetXY(60 * 12,( 100 - 70) * 12); Pirate6->GetTransforms()->SetXY(0 * 12,( 100 - 80) * 12 ); Game.AddObject( Pirate1); Game.AddObject( Pirate2); Game.AddObject( Pirate3); Game.AddObject( Pirate4); Game.AddObject( Pirate5); Game.AddObject( Pirate6); Bateau_Script->objectifmax = 6; HistoireStage2(); break; case 3: Pirate1->GetTransforms()->SetXY(54 * 12,( 100 - 54) * 12); Pirate2->GetTransforms()->SetXY(24 * 12,( 100 - 72) * 12); Pirate3->GetTransforms()->SetXY(39 * 12,( 100 - 23) * 12 ); Pirate4->GetTransforms()->SetXY(8 * 12,( 100 - 40) * 12); Pirate5->GetTransforms()->SetXY(68 * 12,( 100 - 26) * 12); Pirate6->GetTransforms()->SetXY(49* 12,( 100 - 93) * 12 ); Pirate7->GetTransforms()->SetXY(4 * 12,( 100 - 43) * 12); Pirate8->GetTransforms()->SetXY(13 * 12,( 100 - 4) * 12); Pirate9->GetTransforms()->SetXY(40 * 12,( 100 - 95) * 12 ); Pirate9->GetTransforms()->SetXY(40 * 12,( 100 - 95) * 12 ); Game.AddObject( Pirate1); Game.AddObject( Pirate2); Game.AddObject( Pirate3); Game.AddObject( Pirate4); Game.AddObject( Pirate5); Game.AddObject( Pirate6); Game.AddObject( Pirate7); Game.AddObject( Pirate8); Game.AddObject( Pirate9); Bateau_Script->objectifmax = 9; HistoireStage3(); break; } //************Lancement du jeu************// Game.Game(); // Lancement du jeu. return 1; } extern "C" { int AddIn_main(int isAppli, unsigned short OptionNum) { Menu(); return 1; } #pragma section _BR_Size unsigned long BR_Size; #pragma section #pragma section _TOP int InitializeSystem(int isAppli, unsigned short OptionNum) { return INIT_ADDIN_APPLICATION(isAppli, OptionNum); } #pragma section }