fin explication des touches
This commit is contained in:
@@ -11,13 +11,24 @@
|
||||
|
||||
int start (void) {
|
||||
|
||||
couleur green, grey, yellow, red, black;
|
||||
couleur green, grey, yellow, red, black, white;
|
||||
|
||||
int** tableau = plateau_init();
|
||||
|
||||
int i, j;
|
||||
|
||||
|
||||
char* texte1 = "espace = lancer";
|
||||
|
||||
char* texte2 = "espace = pause";
|
||||
|
||||
char* texte3 = "echap = quitter";
|
||||
|
||||
int score=0;
|
||||
|
||||
char* num_score = "score : 00000";
|
||||
|
||||
|
||||
InitialiserGraphique();
|
||||
|
||||
/*initialisation de la taille de la fenetre de jeux*/
|
||||
@@ -48,6 +59,24 @@ int start (void) {
|
||||
RemplirRectangle( 1241, 17, 3, 806);
|
||||
RemplirRectangle( 1241, 820, 195, 3);
|
||||
RemplirRectangle( 1433, 17, 3, 806);
|
||||
|
||||
|
||||
/*affichage fonction des touches*/
|
||||
|
||||
white = CouleurParComposante(255,255,255);
|
||||
ChoisirCouleurDessin(white);
|
||||
EcrireTexte(1250, 300, texte1, 1);
|
||||
EcrireTexte(1250, 345, texte2, 1);
|
||||
EcrireTexte(1250, 390, texte3, 1);
|
||||
|
||||
/*affichage compteur pomme (score)*/
|
||||
|
||||
EcrireTexte(1250, 600, num_score, 2);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -68,8 +97,8 @@ int start (void) {
|
||||
green = CouleurParComposante(50,205,50);
|
||||
ChoisirCouleurDessin(green);
|
||||
RemplirRectangle(20*(j+1),20*(i+1),20,20);
|
||||
|
||||
}
|
||||
|
||||
if ( tableau[i][j] == 1 || tableau[i][j] == -1 || tableau[i][j] == -2) {
|
||||
|
||||
yellow = CouleurParComposante(255,255,0);
|
||||
|
BIN
snake/lancement
BIN
snake/lancement
Binary file not shown.
Reference in New Issue
Block a user