Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<stdio.h>
- #include<stdlib.h>
- #include<ctype.h>
- int main()
- {
- int num;
- int error;
- int VariableRace;
- int WizardLevel;
- int friendship;
- printf("Please only use the numbers 1,2 and 3 to select different options");
- printf("Which race are you?\n1.Goblin\n2.Elf\n3.Wizard\n");
- scanf("%d",&num);
- error=(isdigit(num));
- if (error==0)
- {
- switch(num)
- {
- case 1:
- printf("\tHave you:\n\t1.Eaten\n\t2.Not Eaten\n");
- scanf("%d",&VariableRace);
- if(VariableRace==2)
- {
- printf("Go eat you horrible goblin");
- break;
- case 2:
- printf("\tDo you have the power of\n\t1.Sight\n\t2.Sound\n");
- scanf("%d",&VariableRace);
- break;
- case 3:
- printf("\tWhat level of wizarding are you at:\n\t1.High\n\t2.Medium\n\t3.Low\n");
- scanf("%d",&WizardLevel);
- switch(WizardLevel)
- {
- case 1:
- printf("\t\tYou have insight into the wizarding world but what element have\n\t\tyou mastered?\n\t\t1.Fire\n\t\t2.Wind\n\t\t3.Water\n");
- scanf("%d",&VariableRace);
- break;
- case 2:
- printf("\t\tYou may have passed the basics but can you:\n\t\t1.Fly\n\t\t2.Turn Invisible\n");
- scanf("%d",&VariableRace);
- break;
- case 3:
- printf("\t\tGo back to wizarding school");
- break;
- }
- }
- if (VariableRace==1)
- {
- printf("You are welcome into my Dungeon filled with Dragons however are you \n1.friend?\n2.foe?");
- scanf("%d",&friendship);
- if (friendship==1)
- {
- print("Please come in and make yourself at home");
- }
- else
- {
- printf("YOU DIED");
- }
- }
- else
- {
- printf("You are not welcome in my abode");
- }
- system("pause");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement