1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98
| #include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
#include <string.h>
#include <windows.h>
#include "dico.h"
int gagne(int MotTrouve[]);
int rechercheMot(char Mot, char MotSecret[], int MotTrouve[]);
char lireCaractere();
int main(int argc, char* argv[])
{
char Mot = 0;
char MotSecret[100] = {0};
int *MotTrouve = NULL;
long coupsRestants = 3;
long i = 0;
printf("Bienvenue mlle coco, je te remercie d avoir activer le timing hahaha");
fflush(stdout);
Sleep(30000);
printf("Voila un petit code cnsg celui ci sign");
for (i=0; i < 7; i++);
if(MotSecret[i])
printf("%c", MotSecret[i]);
else
printf("*");
while (coupsRestants > 0 && !gagne(MotSecret))
{
printf("\n\nIl ne te reste plus que %ld coups a jouer", coupsRestants);
fflush(stdout);
Sleep(10000);
printf("\n Un ti indice ? il peut s ecrire aussi 0010100101010 n/n");
if(!rechercheMot(MotSecret, MotSecret, MotTrouve))
{
coupsRestants--;
}
}
if(gagne(MotTrouve))
printf("\n\nFelicitation !! Mais je n en ai pas encore finis avec toi !! Jettes un coup d oeil à tes emails, le jeu poursuis son court ! mouhahaha...");
else
printf("\n\nSuppression des donnees informatiques.............");
printf("\n\nc:/windows/system..............................................removed.");
printf("\n\nc:/windows/system32..............................................removed.");
fflush(stdout);
Sleep(10000);
printf("\n\nHaha plaisanterie mise a part, je vois que tu as echoues hein ! Bien, je te laisse une seconde chance, tu viens de recevoir un email, jettes y un coup d oeil...");
fflush(stdout);
Sleep(10000);
int rechercheMot(char Mot, char MotSecret[], int MotTrouvee[])
{
long i = 0;
int bonMot = 0;
for (i = 0 ; MotSecret[i] != '\0' ; i++)
{
if (Mot == MotSecret[i])
{
bonMot = 1;
MotTrouvee[i] = 1;
}
}
}
return 0;
} |
Partager