diff options
Diffstat (limited to 'labb5')
| -rwxr-xr-x | labb5/src/boggleplay.cpp | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/labb5/src/boggleplay.cpp b/labb5/src/boggleplay.cpp index da03d93..60e45c6 100755 --- a/labb5/src/boggleplay.cpp +++ b/labb5/src/boggleplay.cpp @@ -12,11 +12,7 @@ #include <string> -/* - * Plays one game of Boggle using the given boggle game state object. - */ -void playOneGame(Boggle& boggle) { - boggle.clear(); +void setup_board(Boggle& boggle) { bool input_custom_board = yesOrNo("Input custom board? "); if (input_custom_board) { string input_board; @@ -36,6 +32,15 @@ void playOneGame(Boggle& boggle) { } else { boggle.shuffle(); } +} + +/* + * Plays one game of Boggle using the given boggle game state object. + */ +void playOneGame(Boggle& boggle) { + boggle.clear(); + setup_board(boggle); + string user_input; while (true) { std::cout << "It's your turn!" << std::endl; |
