|
@ -17,6 +17,7 @@ void draw_hangman(int attempts); |
|
|
void add_guessed_letter(char* guessed_letters, char guessed_letter); |
|
|
void add_guessed_letter(char* guessed_letters, char guessed_letter); |
|
|
char eingabe_buchstabe(); |
|
|
char eingabe_buchstabe(); |
|
|
void lade_secret_word(char* secret_word, int level, char* path); |
|
|
void lade_secret_word(char* secret_word, int level, char* path); |
|
|
|
|
|
void show_letters(char secret_word[100], char guessed_letters[100]); |
|
|
|
|
|
|
|
|
void protokoll(){ |
|
|
void protokoll(){ |
|
|
clear_screen(); |
|
|
clear_screen(); |
|
@ -292,3 +293,12 @@ void lade_secret_word(char* secret_word, int level, char* path){ |
|
|
fclose(file); |
|
|
fclose(file); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
void show_letters(char secret_word[100], char guessed_letters[100]){ |
|
|
|
|
|
printf("Erratene Buchstaben: "); |
|
|
|
|
|
for(int i = 0; i < strlen(secret_word); i++) { |
|
|
|
|
|
if(strchr(guessed_letters, secret_word[i])){ |
|
|
|
|
|
printf("%c ", secret_word[i]); |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
} |