Merge pull request 'simon' (#4) from simon into main

This commit is contained in:
2025-11-03 20:17:20 +01:00
3 changed files with 76 additions and 33 deletions
+7 -5
View File
@@ -37,17 +37,19 @@ int main(int argc, char *argv[])
placedWords = createWordSalad(wordSalad, SALAD_SIZE, words, wordCount);
// Check if all words were successfully placed
// Start the game if successful
// error message if some words couldn't be placed
if (placedWords < wordCount)
{
fprintf(stderr, "some words couldn't be placed\n");
int notPlacedNum = wordCount - placedWords;
fprintf(stderr, "%d word(s) couldn't be placed\n", notPlacedNum);
exitCode = EXIT_FAILURE;
}
// TODO:
// Start the game if successful
// Start the game if all words were successfully placed
else
{
startGame(wordSalad, SALAD_SIZE, words, wordCount, 800);
}
}
else
{