Mise en commun du code.
This commit is contained in:
@@ -94,7 +94,6 @@ void choisirMot(string nomFichier, int maximum) {
|
||||
ouvrirFichier(monFlux, nomFichier);
|
||||
string mot = goToLine(monFlux, numeroLigne);
|
||||
fermerFichier(monFlux);
|
||||
cout << numeroLigne << " " << mot;
|
||||
}
|
||||
string goToLine(fstream& monFlux, int numeroLigne) {
|
||||
string mot;
|
||||
@@ -104,6 +103,19 @@ string goToLine(fstream& monFlux, int numeroLigne) {
|
||||
return mot;
|
||||
}
|
||||
|
||||
void afficherMenuJouer() {
|
||||
cout << setw(83) << "=============================================\n";
|
||||
string motPlayer;
|
||||
do
|
||||
{
|
||||
cout << setw(69) << "Saisir votre mot : ";
|
||||
cin >> motPlayer;
|
||||
} while (motPlayer.length() > 3);
|
||||
|
||||
|
||||
cout << setw(66) << "Votre mot est : " << motPlayer;
|
||||
}
|
||||
|
||||
/*====================================
|
||||
2 - OPTIONS
|
||||
====================================*/
|
||||
|
||||
Reference in New Issue
Block a user