I have just finished my tic tac toe game but wanted to make it look nicer so i added some colors at the winning scene...
cout << "congratulations player 1!" << endl;
cout << "[W][I][N]" << endl;
cout << "[W][I][N]" << endl; // checking if the game has been won by O
cout << "[W][I][N]" << endl;
system("color 01");
Sleep(400);
system("color 01");
Sleep(400);
system("color 02");
Sleep(400);
system("color 03");
Sleep(400);
system("color 04");
Sleep(400);
system("color 05");
Sleep(400);
system("color 06");
Sleep(400);
system("color 07");
Sleep(400);
system("color 08");
Sleep(400);
system("color 09");
Sleep(400);
getch();
return 0;
I was wondering if there is anyway that i can make the colors loop while its waiting for the user to input a character so that the colors don't just stop?