diff --git a/Start_Linux/game.c b/Start_Linux/game.c index 11034ad..8bd3506 100644 --- a/Start_Linux/game.c +++ b/Start_Linux/game.c @@ -13,6 +13,8 @@ // Creates the word salad by placing words randomly and filling empty spaces int createWordSalad(char salad[MAX_SEARCH_FIELD_LEN][MAX_SEARCH_FIELD_LEN], unsigned int searchFieldLen, char words[][MAX_WORD_LEN], unsigned int wordCount) { + srand(time(NULL)); + int row, col, placedWords = 0; // Gesamtes Feld auf 0 setzen diff --git a/Start_Windows/game.c b/Start_Windows/game.c index 11034ad..8bd3506 100644 --- a/Start_Windows/game.c +++ b/Start_Windows/game.c @@ -13,6 +13,8 @@ // Creates the word salad by placing words randomly and filling empty spaces int createWordSalad(char salad[MAX_SEARCH_FIELD_LEN][MAX_SEARCH_FIELD_LEN], unsigned int searchFieldLen, char words[][MAX_WORD_LEN], unsigned int wordCount) { + srand(time(NULL)); + int row, col, placedWords = 0; // Gesamtes Feld auf 0 setzen