résolution du problème avec l'affichage des thèmes
This commit is contained in:
@@ -17,9 +17,7 @@ using namespace std;
|
|||||||
extern const int LARGTIC;
|
extern const int LARGTIC;
|
||||||
string ICONJ1 = "X";
|
string ICONJ1 = "X";
|
||||||
string ICONJ2 = "O";
|
string ICONJ2 = "O";
|
||||||
string ICONJ1 = "X";
|
string style = "themes/themeSea.txt";
|
||||||
string ICONJ2 = "O";
|
|
||||||
string style;
|
|
||||||
int codeConsole = 0;
|
int codeConsole = 0;
|
||||||
|
|
||||||
fstream monFlux;
|
fstream monFlux;
|
||||||
@@ -104,6 +102,7 @@ void afficherImageTableau(std::string grid[][LARGTIC], std::string style) {
|
|||||||
iconJ2;
|
iconJ2;
|
||||||
|
|
||||||
// Faire une fonction pour retenir le th<74>me s<>lectionn<6E> par le joueur!!!!
|
// Faire une fonction pour retenir le th<74>me s<>lectionn<6E> par le joueur!!!!
|
||||||
|
|
||||||
ouvrirFichier(monFlux, style);
|
ouvrirFichier(monFlux, style);
|
||||||
if (monFlux) {
|
if (monFlux) {
|
||||||
while (!monFlux.eof()) {
|
while (!monFlux.eof()) {
|
||||||
@@ -339,20 +338,19 @@ void historiqueDesScores() {
|
|||||||
void changerLeTheme() {
|
void changerLeTheme() {
|
||||||
string grid[LARGTIC][LARGTIC] = {ICONJ1, ICONJ2};
|
string grid[LARGTIC][LARGTIC] = {ICONJ1, ICONJ2};
|
||||||
system("cls");
|
system("cls");
|
||||||
cout << endl << "Changer le theme du jeu Tic Tac Toe" << endl
|
|
||||||
<< "Options des styles: " << "\nA) Ocean"
|
|
||||||
<< "\nB) Fantaisie" << "\nC) Espace"
|
|
||||||
<< "\nD) Animaux" << "\nQ) Revenir en arriere"
|
|
||||||
<< "\nChoisir une option: ";
|
|
||||||
choix = toupper(_getche());
|
|
||||||
cout << endl;
|
|
||||||
|
|
||||||
do {
|
do {
|
||||||
|
cout << endl << "Changer le theme du jeu Tic Tac Toe" << endl
|
||||||
|
<< "Options des styles: " << "\nA) Ocean"
|
||||||
|
<< "\nB) Fantaisie" << "\nC) Espace"
|
||||||
|
<< "\nD) Animaux" << "\nQ) Revenir en arriere"
|
||||||
|
<< "\nChoisir une option: ";
|
||||||
|
choix = toupper(_getche());
|
||||||
|
cout << endl;
|
||||||
|
|
||||||
switch (choix) {
|
switch (choix) {
|
||||||
case 'A':
|
case 'A':
|
||||||
style = "themes/themeSea.txt";
|
style = "themes/themeSea.txt";
|
||||||
afficherImageTableau(grid, style);
|
afficherImageTableau(grid, style);
|
||||||
system("PAUSE");
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'B':
|
case 'B':
|
||||||
@@ -375,6 +373,7 @@ void changerLeTheme() {
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
cout << "\nChoisir une option valide. \n";
|
cout << "\nChoisir une option valide. \n";
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
} while (choix != 'Q');
|
} while (choix != 'Q');
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user