online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code   
Language
# Gavin Nielsen # 8 Dec 2019 # Text based game based on the Salem Witch Trials # _____ _ _ _ _ # / ____| (_) | \ | (_) | | # | | __ __ ___ ___ _ __ | \| |_ ___| |___ ___ _ __ # | | |_ |/ _` \ \ / / | '_ \ | . ` | |/ _ \ / __|/ _ \ '_ \ # | |__| | (_| |\ V /| | | | | | |\ | | __/ \__ \ __/ | | | # \_____|\__,_| \_/ |_|_| |_| |_| \_|_|\___|_|___/\___|_| |_| # Level 1: -Learn about Salem # -Supporting information # -Learn basics of game # -Tutorial level # Level 2 -Tell the other girls what your story is so there are no differences # -Find where the others are # -Tell them what your story is # -Get to decide? # Level 3 -Choose who to accuse # -Don't accuse too many or you might be hanged for lying # -Choose how to act in court # -Points given for how well the lies hold up # Level 4 -John is accusing you # -Support your claims and get out of the issue # -Points for ability to decide quickly and believably # This game is a text-based game that allows players to envision themselves in Salem Massachusetts during the notorious Salem Witch Trials. # I created this game as a project in class after reading The Crucible by Arthur Miller. # Game Program Is Contained In This File import time from os import system, name playerPoints = 0 gameContinue = "Press Enter To Continue" end = "Press Enter To End" # Function To Clear Screen - call clear() def clear(): # for windows if name == 'nt': _ = system('cls') # for mac and linux(here, os.name is 'posix') else: _ = system('clear') # Game Opening print() print(" _ __________ __________ __ _________ __________ _____ ___ __ ________ ___ ") print("| | / / ____/ / / ____/ __ \/ |/ / ____/ /_ __/ __ \ / ___// | / / / ____/ |/ / ") print("| | /| / / __/ / / / / / / / / /|_/ / __/ / / / / / / \__ \/ /| | / / / __/ / /|_/ / ") print("| |/ |/ / /___/ /___/ /___/ /_/ / / / / /___ / / / /_/ / ___/ / ___ |/ /___/ /___/ / / / ") print("|__/|__/_____/_____/\____/\____/_/ /_/_____/ /_/ \____/ /____/_/ |_/_____/_____/_/ /_/ ") print() print() print("This Game Works Best In Full Screen") time.sleep(5) clear() time.sleep(.5) # Instructions print() print() print() print(""" This game is played through your keyboard. Any actions you take will be typed out. The commands issued in this game are done in the form of numbers. The number will be listed in square brackets followed by what command it is. Example: [1] Play the game or, [2] Play the game with more gusto. """) gameContinue = input("Press Enter To Continue ") clear() print() print() print() playerName = input("What is your name, player?: ") time.sleep(3) clear() time.sleep(2) # Level 1 Buildup print() print() print() print( "In the British colony of Massachusetts there was a witchcraft hysteria that resulted in the execution of twenty and the jailing of at least 100 others during 1692. ") time.sleep(5) print("The incident was unprecedented for the area but was not unique. ") time.sleep(5) print( "Witchcraft trials had swept across Europe, resulting in thousands of executions in the sixteenth and seventeenth centuries. ") time.sleep(5) print("Many were guilty of only continuing traditions lasting from the pre-Christian era of Europe. ") time.sleep(5) print("In the era of the combination of church and state, witch hunts were often motivated by political issues. ") time.sleep(7) print() print("For the colonists in Salem it may have been caused by the hardships they had suffered from the first day. ") time.sleep(5) print( "They found themselves at odds with forces out of their control - harsh weather, sickness, death, and insect infestations. ") time.sleep(5) print("Many of these were associated with the evil forces from witches and the Devil. ") time.sleep(7) print( "Those who lived in the small village of Salem were quick to blame these forces when several girls, including the minister's daughter, fell ill with seizures and unconsciousness. ") time.sleep(5) print("Especially after learning they had danced in the forest with the minister's slave, Tituba. ") time.sleep(7) print() print( "Tituba and two older women were tried as witches, but the hunt continued until there were several well-known and liked people accused. ") print() print() print() gameContinue = input("Press Enter To Continue ") time.sleep(3) clear() # Level 1 Gameplay print() print() print() print( "You find yourself standing outside of the town meeting house. Down the road there are houses, one of which has several people congregating around it. ") playerChoice = input("Do you [1] Go into the meeting house or [2] Go towards the house down the road? : ") if playerChoice == '1': print("You approach the door and go to open it, only to find the door is locked. ") elif playerChoice == '2': print("You approach the house to find people gathered around the door and inside the house. ") else: print("That is not an option. ") playerChoice = input("Do you [1] Go into the meeting house or [2] Go towards the house? : ") if playerChoice == '1': print("You approach the door and go to open it, only to find the door is locked. ") elif playerChoice == '2': print("You approach the house to find people gathered around the door and inside the house. ") else: print("You approach the door and go to open it, only to find the door is locked. ") time.sleep(2) print("There are people talking both inside and outside the house. ") playerChoice = input( "Do you [1] Talk to the people outside the house, [2] talk to the people inside the house, or [3] leave and go back to the meeting house? : ") if playerChoice == "1": print("The people outside the house do not seem very friendly, but tell you that the minister's daughter is sick. ") elif playerChoice == "2": print("The people inside the house do not seem very friendly, but tell you that the minister's daughter is sick. ") elif playerChoice == "3": print( "You leave and go back to the meeting house, but the door is still locked and you are taken to jail for attempted robbery of the meeting house.") time.sleep(3) print("You find yourself being tried for attempted robbery of the meeting house.") playerChoice = input("Do you [1] Say you were looking for the reverend, or [2] Agree to the charges? : ") if playerChoice == "1": print("The court tells you that he is in his home grieving, and one of the villagers will take you to him. ") else: print("You are found not guilty of attempted robbery, and are told you will be taken to the reverend to pray.") else: print( "That is not an option. The people outside the house begin to involve you in their conversation, but are not very friendly. They tell you that the reverend's daughter is ill.") print( "As you pry for more information from the villagers, a farmer by the name of John Proctor exits the upstairs of the reverend's house followed by several other people.") print("As he walks by you get a feeling that you have met him before. ") print( "The girls who walks out after him, who you believe is the reverend's niece, also reminds you of someone you know. ") playerChoice = input( "Do you [1] Follow after John to see if you know him, or [2] go to Abigail to see if you know her? : ") if playerChoice == "1": print("John tells you that he might have met you in town once, but that he doesn't know you. ") time.sleep(3) playerChoice = input( "Do you [1] Turn around and talk to Abigail, or [2] go back into the reverend's house to talk to him? : ") if playerChoice == "1": print("You follow after Abigail but you lose sight of her, and decide to go back to the reverend's house. ") else: print("You go back to the reverend's house. ") elif playerChoice == "2": print( "Abigail tells you that you had danced in the forest with her, and that you should know her, but you cannot talk about it now. ") time.sleep(3) playerChoice = input( "Do you [1] Turn around and talk to John, or [2] go back into the reverend's house to talk to him? : ") if playerChoice == "1": print( "You turn around to talk to John, but you cannot find him. You decide to go back into the reverend's house. ") if playerChoice == "2": print("You go back to the reverend's house. ") else: print("You stay in the reverend's house. ") time.sleep(3) print( "As you are in the reverend's house you notice that there are many people going into the upstairs room and then leaving several minutes later. ") playerChoice = input("Do you [1] Ask someone leaving the room what is going on, or [2] Go into the room? : ") if playerChoice == "1": print("You are told by a couple leaving the room that the reverend's daughter, Betty, is ill and will not wake up.") elif playerChoice == "2": print("You walk into the room to find a girl laying asleep on the bed with the reverend kneeling next to her. ") print("You want to ask who the girl is, but do not out of kindness. ") else: print("You stay in the main room of the house. ") time.sleep(3) print("As night nears a girl from the village who you think you know offers you a place to stay.") playerChoice = input( "Do you [1] take her offer and spend the night with her, or [2] tell her no and choose to find your own place? : ") if playerChoice == "1": print("She takes you home with her to spend the night. ") elif playerChoice == "2": print("You tell the girl no, but she asks again to make sure. ") playerChoice = input( "Do you [1] take her offer and spend the night with her, or [2] tell her no and choose to find your own place? : ") if playerChoice == "1": print("She takes you home with her to spend the night.") elif playerChoice == "2": print("You tell her no and choose to spend the night on the street. ") else: print("You do not answer her and she leaves, forcing you to spend the night on the street. ") else: print("You do not answer her and she leaves, forcing you to spend the night on the street. ") time.sleep(5) # Level 2 print("Welcome To Level 2") time.sleep(5) clear() time.sleep(2) print("You awake to find yourself laying in the street, not quite remembering how you got there.") print("You recall seeing the reverend's daughter yesterday, but cannot recall anything else.") print("After sitting up for a couple of minutes you see several people walking to the meeting house.") print("After watching several people walk past you realize you should probably get up.") playerChoice = input("Do you [1] Follow the people to the meeting house, or [2] Go look around the town for more clues of where you are? : ") if playerChoice == "1": print("You follow the crowd to the meeting house, but are turned away at the door for how you look. ") elif playerChoice == "2": print("You go to look around the town, but are asked several time where you are going, slowly getting pulled toward the meeting house. ") else: print("Invalid command. In the time it took you to think, you are slowly pulled toward the meeting house. ") print("You are told to stay outside the meeting house so you can hear it, but to not distract the other goers. ") time.sleep(3) print("As the reverend preaches you listen in and hear him preaching of witchcraft, subtly mentioning his daughter and another girl. ") print("Hearing this causes you to remember dancing with the girls he mentioned.") print("Now knowing where you are and what is happening, you must decide if you are going to try to avoid the accusations or blame Tituba like Abigail had the day before. ") time.sleep(3) print("As you are contemplating what to do, the reverend finishes his sermon, and several girls walk out of the meeting house. ") print("As Abigail walks by she tells you to follow her so that you can discuss your plans. ") time.sleep(2) print("As you follow Abigail to the reverend's house, she tells you that you cannot tell anyone that you had danced in the forest with them. ") time.sleep(3) print("When you get to the reverend's house Abigail asks if you know where the other girls are. ") playerChoice = input("Do you answer [1] What girls are you talking about, or [2] No, do you? : ") if playerChoice == "1": print("Abigail respond, \"The other girls we danced with. Who else would I be talking about?\" ") print("Abigail asks if you remember what happened. ") playerChoice = input("Do you respond [1] Not really, can you remind me? Or [2] I thinks so? : ") if playerChoice == "1": print("Abigail ponders your response for a moment. ") time.sleep(3) print("When she does speak, she tells you that you had been dancing in the woods with herself and several other girls when you were caught by her uncle, Reverend Parris. ") print("She then tells you that her cousin, Betty, won't wake up and that Parris has asked for a witchcraft expert, Reverend Hale, to come look at her. ") elif playerChoice == "2": print("Abigail ponders your response for a moment. ") time.sleep(3) print("When Abigail speaks, she tells you that she hopes you remember after almost being caught. ") else: print("When you don't respond, Abigail says that when you tripped on a rock while you were running out of the forest must have hit your head. ") elif playerChoice == "2": print("Abigail respond \"I don't, that's why I asked you.\" ") else: print("That is not a valid choice. Abigail says \"I guess you don't then.\" after you take too long to respond. ") time.sleep(3) print("Abigail begins to speak, saying that since Reverend Hale, the witchcraft expert, is coming to Salem to look at Betty, she thinks he will ask about you and the other girls dancing in the woods. ") print("She says that if you are accused you should tell Reverend Hale that someone else forced you to do it through witchcraft. ") playerChoice = input("Do you [1] Argue with Abigail and say that you don't believe that is the right solution, or [2] Agree with Abigail? : ") if playerChoice == "1": print("Abigail tells you that if you don't follow her plan or there is a chance of her being hanged for witchcraft she is going to blame you. ") elif playerChoice == "2": print("Abigail says that you made the right decision, but that you need to tell the other girls what the plan is. ") else: print("After taking to long to respond, Abigail tells you to find the other girls and tell them what she told you. ") time.sleep(2) print("As you are leaving Reverend Parris' home, you ponder telling the other girls a different story and framing Abigail. ") playerChoice = input("Do you [1] Do as Abigail told you to, or [2] Tell the other girls to frame Abigail and only her. ") if playerChoice == "1": print("You decide to go with Abigail's plan for fear of being framed by Abigail. ") elif playerChoice == "2": print("You tell yourself that you are going to frame Abigail, but Abigail walks out of the door to remind you that she will frame you if you try anything else. Causing you to do as she told you earlier. ") else: print("You stand outside the door thinking, as Abigail walks out and tells you to hurry and tell the others. ") time.sleep(3) print("As you begin to walk away to find the other girls, you think about who all of the other girls are. ") print("Out of the following people, choose the person who danced in the woods with you. ") playerPersonChoice = input("[1] Elizabeth Proctor [2] Mercy Lewis [3] Rebecca Nurse? : ") if playerPersonChoice == "2": print("That is a person you danced with. +5 points.") playerPoints = playerPoints + 5 else: print("You did not dance with this person. -5 points") playerPoints = playerPoints - 5 print("Out of the following people, who did you not dance with?") playerPersonChoice = input("[1] Ruth Putnam [2] Ann Putnam [3] Mary Warren? : ") if playerPersonChoice == "2": print("You did not dance with this person. +5 points") playerPoints = playerPoints - 5 else: print("You danced with this person. -5 points.") playerPoints = playerPoints - 5 time.sleep(3) print("As you are walking, you realize that you have no idea who you are going to talk to first. ") playerChoice = input("Do you [1] Talk to Mercy Lewis first, or [2] Talk to Ruth Putnam first, or [3] Talk to Mary Warren first? : ") if playerChoice == "1": playerPersonOne = "Mercy Lewis" print("You go to talk to Mercy Lewis, but must find where she lives. ") playerChoice = input("Do you [1] Ask for directions, or [2] Go to where you think her house is? : ") if playerChoice == "1": print("You ask the townspeople for directions, but they are unwilling to help you. Forcing you to find her on your own. ") else: print("You ponder where she lives, and wonder off in the direction you believe she lives in. ") elif playerChoice == "2": playerPersonOne = "Ruth Putnam" print("You go to talk to Ruth Putnam, but must find where she lives. ") playerChoice = input("Do you [1] Ask for directions, or [2] Go to where you think her house is? : ") if playerChoice == "1": print( "You ask the townspeople for directions, but they are unwilling to help you. Forcing you to find her on your own. ") else: print("You ponder where she lives, and wonder off in the direction you believe she lives in. ") else: playerPersonOne = "Mary Warren" print("You go to talk to Mary Warren, but must find where she lives. ") playerChoice = input("Do you [1] Ask for directions, or [2] Go to where you think her house is? : ") if playerChoice == "1": print("You ask the townspeople for directions, but they are unwilling to help you. Forcing you to find her on your own. ") else: print("You ponder where she lives, and wonder off in the direction you believe she lives in. ") time.sleep(1) if playerPersonOne == "Mary Warren": print("As you wander off in search of Mary Warren, she walks out of a building right in front of you. ") else: print("As you wander off in search of " + playerPersonOne + " Mary Warren walks out of a building in front of you. ") playerChoice = input("Do you tell Mary Warren [1] What Abigail told you to say, or [2] To blame Abigail if you get tried? : ") if playerChoice == "1": print("You tell Mary Warren what Abigail told you to say, to which Mary Warren says Abigail already told her. ") elif playerChoice == "2": print("You tell Mary Warren to blame Abigail if she gets tried, but she says Abigail already told her to blame someone else. ") else: print("After not responding to Mary Warren, she tells you that Abigail told her to blame someone else if she gets tried. ") print("As you are talking to Mary Warren, Abigail and the other two girls walk up to you and Mary Warren. ") time.sleep(2) print("As Abigail gets closer, she tells you that she already told the others and that everyone's story needs to match now. ") time.sleep(2) print("Abigail suggests saying Tituba forced you to summon spirits with her.") playerChoice = input("Do you [1] Agree with Abigail and follow that story, or [2] Disagree with Abigail and suggest your own story? : ") if playerChoice == "1": print("You agree with Abigail, and after talking some more you all go home for the evening. ") elif playerChoice == "2": print("You disagree with Abigail, but after Abigail threatens your life you are forced to agree for fear dying. ") else: print("When you don't respond, Abigail assumes you are going to follow her story, and threatens anyone who decides not to. ") print("You go to a rundown shack on the edge of town to spend the night out of the weather. ") time.sleep(5) # Level 3 print("When you awake you find yourself in the same shack as you fell asleep in, but there is now a cat laying with you. ") playerChoice = input("Do you [1] Wake the cat up, or [2] Go back to sleep? : ") if playerChoice == "1": print("You wake the cat up and it scurries off. ") else: time.sleep(3) print("You go back to sleep and wake up without the cat. ") print("You leave the shack to go find food and meet Abigail on the way. ") print("She tells you that she told Reverend Hale the story and he believed it. ") print("She tells you that there is now going to be trials to see who is guilty of witchcraft and that you have to help the court decide. ") print("As the day goes on Abigail tells you more about how you are going to act in court and to just follow her lead. ") time.sleep(2) print("The rest of the day is otherwise uneventful and you go back to your shack to sleep and prepare for the next day. ") time.sleep(5) print("Several days pass without many events, slowly building up to your first day in court. ") time.sleep(2) print("On the first day in court, you are told to tell the court who you know of that has participated in witchcraft to your knowledge. ") print("Abigail accuses Tituba again so that it is on the courts record, and then continues to name several other people, who are dismissed for their good standing. ") time.sleep(1) print("As the group thinks of people to accuse, Judge Hawthorne asks if there is anybody you feel should be tried. ") playerChoice = input("Do you respond [1] There is somebody I wish to accuse, or [2] There is nobody I would like to accuse? : ") if playerChoice == "1": print("The judge asks who you would like to accuse. ") playerChoice = input("[1] Tituba [2] Rebecca Nurse [3] Goody Osborn [4] Goody Good : ") if playerChoice == "1": print("Judge Hawthorne responds: 'Abigail has already accused her.' ") playerPoints = playerPoints - 2 elif playerChoice == "2": print("Judge Hawthorne responds: 'I don't think such an upstanding woman could do such a thing, but we will try her nonetheless.' ") playerPoints = playerPoints +1 elif playerChoice == "3": print("Judge Hawthorne responds: 'We will have her brought in to be tried.' ") playerPoints = playerPoints + 5 elif playerChoice == "4": print("Judge Hawthorne responds: 'We will have her brought in to be tried.' ") playerPoints = playerPoints + 5 else: print("Judge Hawthorne responds: 'I do not know who you speak of, but this court does not know of them.' ") elif playerChoice == "2": print("The judge looks at you, studying you, and then turns to the other girls and asks them the same question. ") else: print("You do not respond, so Judge Hawthorne asks the other girls the same question. ") print("As your first day of court drones on, you begin to realize that Abigail is enjoying it too much. ") print("As the day ends you go back to the shack you found, to find the cat waiting for you at the door. ") playerChoice = input("Do you [1] Let the cat inside, or [2] Shoo the cat away? : ") if playerChoice == "1": print("You let the cat inside and it waits for you to fall asleep. ") playerPoints = playerPoints + 1 elif playerChoice == "2": print("You shoo the cat away and sleep alone inside the shack. ") playerPoints = playerPoints - 1 else: print("You sit and stare at the cat, which eventually runs off, leaving you alone in the shack. ") playerPoints = playerPoints - 1 time.sleep(5) print("The next day in court, Tituba is brought in and tried. ") print("Abigail told you before court started to just follow her lead. ") print("When Abigail begins acting as if Tituba's spirit is attacking her, you have to make a decision. ") playerChoice = input("Do you [1] Follow Abigail's lead, or [2] Act like there are no spirits attacking you? : ") if playerChoice == "1": print("You follow Abigail's lead, convincing Judge Hawthorne that Tituba is attacking you and the other girls with her spirit. ") print("Judge Hawthorne sentences Tituba to be hanged for witchcraft. ") else: print("You act as if there are no spirits and the room, and Abigail turns on you acting as if though your spirit is attacking her as well. ") print("Judge Hawthorne sentences you to be hanged after you cannot explain why you saw no spirits but Abigail was attacked by yours and Tituba. ") time.sleep(5) clear() print("You are hanged next to Tituba.") time.sleep(5) clear() print("Your points accumulated in this game are: " + str(playerPoints)) time.sleep(30) print("Game Ending") exit() time.sleep(3) print("Several days continue with Abigail leading the girls in their lies, with you following her lead. ") print("Many more people are accused and tried. Some are hanged, some are put in jail, and others are let free. ") time.sleep(2) print("Several days later Abigail fell to the floor of Reverend Parris' home and was found with a needle in her stomach. ") print("Abigail accused Elizabeth Proctor of using witchcraft to stab her. ") print("Abigail had told you of her plan to get Elizabeth hanged and then John's love for her would be revealed, but you did not expect her to do it. ") time.sleep(2) print("The day that Elizabeth is supposed to be tried Mary Warren does not come to the court. ") print("When John Proctor comes to the trial for his wife Mary Warren is with him. ") print("He tells Judge Hawthorne that Mary Warren has something to say to the court. ") time.sleep(2) print("Mary Warren tells Judge Hawthorne that the poppet being used to try Elizabeth was hers and was made in court. ") print("After Judge Hawthorne thinks on what Mary Warren said, he decides to bring Abigail in and see if she agrees with what Mary Warren is saying. ") time.sleep(1) print("When Abigail is brought in she denies ever seeing Mary make the poppet, and says that while she worked at the Proctor's there were several poppets kept in the house. ") print("After both John and Mary tell Judge Hawthorn Abigail is lying, she acts as if though Mary is going to attack her with her spirit. ") playerChoice = input("You are now faced with a decision. Do you [1] follow Abigail's lead and act as if though there is a bird in the rafters, or [2] Side with Mary and John against Abigail? : ") if playerChoice == "1": print("You follow Abigail's lead and act as if though Mary is attacking you and the other girls. ") playerPoints = playerPoints + 5 elif playerChoice == "2": print("You side with Mary and John against Abigail, but the other girls do not and begin to act as if though you are attacking them as well. ") print("Judge Hawthorne accuses you of witchcraft and you are tried. ") playerPoints = playerPoints + 2 time.sleep(2) print("At your trial you are sentenced to hanging for witchcraft and are hanged. ") print("Your points total for this game is: " + str(playerPoints)) time.sleep(30) clear() print("End Of Game") time.sleep(5) exit() else: print("You stand in front of Abigail as she screams at the bird. ") print("She swings at the bird with a sharp object she found, striking you in the throat with it. ") playerPoints = playerPoints - 3 time.sleep(2) print("You fall to the ground and lay in a puddle of blood as your life drains from you. ") print("The last face you see is Abigail's. ") time.sleep(5) print("Your points total for this game is: " + str(playerPoints)) time.sleep(30) clear() print("End Of Game") time.sleep(5) exit() print("Mary finally breaks down crying and comes running to Abigail. ") print("She screams that John is the devil and forced her to do it, but is now with God and Abigail. ") time.sleep(2) print("John tells the court that he and Abigail had an affair, but it is not enough to stop what has already begun to happen. ") pritn("He is shackled and slowly being pulled from the building when he yells: ") print(""" A fire, a fire is burning! I hear the boot of Lucifer, I see his filthy face! And it is my face, and yours, Danforth! For them that quail to bring men out of ignorance, as I have quailed, and as you quail now when you know in all your black hearts that this be fraud! God damns our kind especially, and we will burn, we will burn together! """) time.sleep(5) # Fourth Level print("Welcome To the Fourth Level") gameContinue = input("Press Enter To Continue") clear() print("The rest of the day is uneventful, as are most of the following days. ") print("Several months pass with many more trials and many more hangings. ") print("The most notable of these trials was John Proctor's.") time.sleep(2) print("Leading into John's trial, Abigail had been getting better at lying in court, and had planned to use this skill to see John hanged. ") print("Right before John's trial though, Abigail had a conversation with you. ") print("Abigail told you she was going to leave Salem, because there were too many people against her, and offered you a chance to come with. ") characterChoice = input("Do you go with Abigail to an unknown place? [Y]es or [N]o? : ") if characterChoice.lower() == "n": print("You tell Abigail that you won't be going with her. ") print("Abigail leaves, never to be seen again. ") playerPoints = playerPoints + 3 elif characterChoice.lower() == "y": print("You choose to go with Abigail to an unknown place. ") playerPoints = playerPoints - 2 print("You and Abigail leave by boat to an unknown destination. ") time.sleep(2) print("On your way to the port, Abigail decides you are a witch and throws you overboard with your hands and feet tied. ") print("You slowly sink to the bottom of the ocean, and the last thing you see is a fish. ") time.sleep(5) clear() print("Your points accumulated in this game are: " + str(playerPoints)) time.sleep(30) print("Game Ending") exit() else: print("When you don't respond, Abigail tells you that she can't bring someone with who can't think for themselves and leaves you, never to be seen again. ") playerPoints = playerPoints -4 print("As the days go on, John refuses to admit to witchcraft, and stays in jail for the remainder of his life. ") print("John never forgives you for what you did to him, but you are able to go home to your shack every night and see your cat, who waits diligently for you. ") time.sleep(2) print("While John is in jail he accuses you of lying to get him hanged. ") print("Many people believe him, but Judge Hawthorne is questioning whether you did or not. ") print("You must decide what to tell him. ") print() time.sleep(3) print("[1] Tell him that Abigail forced you to go along with her plans. ") print("[2] Tell him that you thought you were doing the right thing. ") print("[3] Tell him that someone forced you to do it through witchcraft. ") characterChoice = input("Enter Your Choice: ") if characterChoice == "1": print("Judge Hawthorne believes you, but John is skeptical that was the only reason. ") playerPoints = playerPoints + 5 elif characterChoice == "2": print("Judge Hawthorne says that you are in the right, but John doesn't believe you. ") playerPoints = playerPoints + 2 elif characterChoice == "3": print("Judge Hawthorn wants to believe you, but cannot be convinced to fully believe you. Saying this only causes John to dislike you more. ") playerPoints = playerPoints - 3 print("After Judge Hawthorne thinks your answer over, he decides the only witch who could have forced you to do what you did is yourself. ") print("Judge Hawthorne decided to try you as a witch, if you were forced by someone else, he believes it will show in this trial. ") print("With the amount of people you have helped accuse, there are very few people willing to defend you. ") time.sleep(2) print("You are tried as a witch, found guilty, and sentenced to hang. ") time.sleep(2) print("You are kept in the jail with the people you helped to put in there, and no one will talk to you. ") print("You are hanged with several other people. ") print("The last thing you see is a crowd cheering for your death. ") time.sleep(7) clear() print("Your points accumulated in this game are: " + str(playerPoints)) time.sleep(30) print("Game Ending") exit() else: print("When you answer in an uninteligable mumble, Judge hawthorne believes that you are a witch and tries you as such. ") playerPoints = playerPoints - 5 print("With the amount of people you have helped accuse, there are very few people willing to defend you. ") time.sleep(2) print("You are tried as a witch, found guilty, and sentenced to hang. ") time.sleep(2) print("You are kept in the jail with the people you helped to put in there, and no one will talk to you. ") print("You are hanged with several other people. ") print("The last thing you see is a crowd cheering for your death. ") time.sleep(7) clear() print("Your points accumulated in this game are: " + str(playerPoints)) time.sleep(30) print("Game Ending") exit() time.sleep(2) print("Before John hangs, he tells you that he has forgiven you, but wishes you had stopped following Abigail sooner. ") print("John hangs and has found peace with himself. ") time.sleep(2) print() print("You live your life out in Salem, finding work as servant in a farmer's house. ") print("Your cat comes and visits you frequently, but cannot stay with you. ") time.sleep(3) clear() print("Congratulations " + playerName + "! You have successfully navigated the risky path of the Salem Witch Trials! ") print() print("Your score was: " + str(playerPoints)) time.sleep(2) time.sleep(10) print() print() print() print() print("Game designed by Gavin Nielsen") time.sleep(2) clear() # End Of Script

Compiling Program...

Command line arguments:
Standard Input: Interactive Console Text

                

                

Program is not being debugged. Click "Debug" button to start program in debug mode.

#FunctionFile:Line
VariableValue
RegisterValue
ExpressionValue