|
|
@ -4,6 +4,7 @@ |
|
|
|
#include <ctype.h> |
|
|
|
#include <string.h> |
|
|
|
#include "quizproject.h" |
|
|
|
|
|
|
|
char answers[NUM_QUESTIONS] = {'B', 'A', 'A','B','A'}; |
|
|
|
|
|
|
|
int* randomNumber() { |
|
|
@ -437,7 +438,7 @@ void displayThankYouMessage(void) { |
|
|
|
printf("*******************************\n\n"); |
|
|
|
} |
|
|
|
|
|
|
|
int main(){ |
|
|
|
void play_quizgame(void){ |
|
|
|
displayInstructions(); |
|
|
|
|
|
|
|
printf(">>Press 's' and Enter start the Game<<\n"); |
|
|
@ -452,7 +453,47 @@ if (score > 2){ |
|
|
|
ask_hard_questions(); |
|
|
|
} |
|
|
|
displayThankYouMessage(); |
|
|
|
return 0; |
|
|
|
} |
|
|
|
|
|
|
|
void play_factorlie() { |
|
|
|
printf("Playing game 2...\n"); |
|
|
|
// code for game 2 goes here |
|
|
|
} |
|
|
|
|
|
|
|
void play_game3() { |
|
|
|
printf("Playing game 3...\n"); |
|
|
|
// code for game 3 goes here |
|
|
|
} |
|
|
|
|
|
|
|
int main() { |
|
|
|
int choice; |
|
|
|
|
|
|
|
printf("Welcome to the Game Menu!\n"); |
|
|
|
printf("1. QuizGame\n"); |
|
|
|
printf("2. Fact or Lie?\n"); |
|
|
|
printf("3. Game 3\n"); |
|
|
|
printf("4. Exit\n"); |
|
|
|
printf("Enter your choice: "); |
|
|
|
scanf("%d", &choice); |
|
|
|
|
|
|
|
switch(choice) { |
|
|
|
case 1: |
|
|
|
play_quizgame(); |
|
|
|
break; |
|
|
|
case 2: |
|
|
|
play_factorlie(); |
|
|
|
break; |
|
|
|
case 3: |
|
|
|
play_game3(); |
|
|
|
break; |
|
|
|
case 4: |
|
|
|
printf("Exiting the Game Menu...\n"); |
|
|
|
break; |
|
|
|
default: |
|
|
|
printf("Invalid choice!\n"); |
|
|
|
} |
|
|
|
|
|
|
|
return 0; |
|
|
|
} |
|
|
|
|
|
|
|
|