WWII The Trail of War - HeroMourne/Hero GitHub Wiki

import random import time DICE = [1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20]

Intro

print("WWII") print("") print("A DAY IN THE LIFE") print("") print("") R_AMMO = 0 P_AMMO = 0 MAGMOR = 35 SCOPE = 0 COOLSTUFF = ["3 green army figures","a compass!","a candy wrapper!","A nintendo switch! Cool!"] Inventory = ["RIFLE","PISTOL","KNIFE","BEANS","WATER","MEDKIT","COOL STUFF"] OUTPUT = random.choice(DICE) if OUTPUT > 0 and OUTPUT < 6: Inventory.append("COOL STUFF") if OUTPUT > 5 and OUTPUT < 11: Inventory.append("PUDDING") if OUTPUT >10 and OUTPUT < 16: R_AMMO = R_AMMO + OUTPUT P_AMMO = P_AMMO + OUTPUT if OUTPUT > 15 and OUTPUT < 17: Inventory.append("GUNS MAGAZINE") if OUTPUT > 16 and OUTPUT < 20: Inventory.append("CIGAR PACK") if OUTPUT == 20: Inventory.append("RIFLE SCOPE") OUTPUT = random.choice(DICE) if OUTPUT > 0 and OUTPUT < 6: Inventory.append("COOL STUFF") if OUTPUT > 5 and OUTPUT < 11: Inventory.append("PUDDING") if OUTPUT >10 and OUTPUT < 16: R_AMMO = R_AMMO + OUTPUT P_AMMO = P_AMMO + OUTPUT if OUTPUT > 15 and OUTPUT < 17: Inventory.append("GUNS MAGAZINE") if OUTPUT > 16 and OUTPUT < 20: Inventory.append("CIGAR PACK") if OUTPUT == 20: Inventory.append("RIFLE SCOPE") X = 0 while X != "" or X == "HeroMourne" or X == "ENTER" or X == "NEW SUPER MARIO BROS" or X == "FIRE RED" or X == "SQUIRTLE" or X == "HIGHSCORES": #Lots and lots of easter eggs! X = input("PRESS ENTER TO START, OR TYPE HIGHSCORES TO SEE THEM!") if X == "HeroMourne": HP = 8 + 27 + 2000 Inventory.append("MRE") Inventory.append("CRYSTAL EGG") Inventory.append("READY PLAYER ONE NOVEL") Inventory.append("DS LITE") print("Created by HeroMourne") elif X == "ENTER": print("I SAID CLICK IT, NOT TYPE IT!") elif X == "NEW SUPER MARIO BROS": Inventory.append("POKEMON DS CARTRIDGE") elif X == "FIRE RED": Inventory.append("POKEBALL") elif X == "SQUIRTLE": Inventory.append("WATER GUN") elif X == "HIGHSCORES": if "WATER GUN" not in Inventory: print("1 HeroM 999 Kills") print("2 00000 000 Kills") print("3 00000 000 Kills") print("4 00000 000 Kills") print("5 00000 000 Kills") print("6 00000 000 Kills") print("7 00000 000 Kills") print("8 00000 000 Kills") print("9 00000 000 Kills") print("10 00000 000 Kills") time.sleep(5) else: print("1 HeroM 999 Kills") print("2 YOU00 998 Kills") print("3 00000 000 Kills") print("4 00000 000 Kills") print("5 00000 000 Kills") print("6 00000 000 Kills") print("7 00000 000 Kills") print("8 00000 000 Kills") print("9 00000 000 Kills") print("10 00000 000 Kills") time.sleep(5) else: HP = 20 print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("")

Intro to game

P_AMMO = 20 R_AMMO = 35 HUNGER = 100 THIRST = 100 MORALE = 100 Kills = 0 print("You are an american infantry soldier in the Torner Division") print("Good luck n00b XD") time.sleep(3) Things = ["You look over a dirt mound and find a soldier charging down a hill giving such a ferocious war cry you stumble backwards","You find a journal full of sketched inventions","You find a pack of (GINGER) ale lol","You find a smooshed pack of cigars, one lit, the rest untouched, next to a corpse with a large sniper bullet hole in his helmet."] while 0 < HP or MORALE > 0 or HUNGER > 0 or THIRST > 0: print(HP) print("HP") print(P_AMMO) print("Bullets") print(R_AMMO) print("Rifle Bullets") print(HUNGER) print("Hunger") print(THIRST) print("Thirst") print(MORALE) print("Morale") Input = input("HELP FOR OPTIONS") if Input == "HELP": print("SCAVENGE, SHOOT PISTOL, SHOOT RIFLE,INTERACT WITH") if Input == "SCAVENGE": Outcome = random.choice(DICE) if Outcome == 1: print("You find nothting") if Outcome == 2: print("You find 3 pistol bullets") P_AMMO = 3 + P_AMMO if Outcome == 3: print("You find 2 rifle shots") R_AMMO = 2 + R_AMMO if Outcome == 4: print("Some chips!") Inventory.append("CHIPS") if Outcome == 5: print("Some PFP, yayyyyy....") Inventory.append("PFP") if Outcome == 6: print("Some PDP, ugh.") Inventory.append("PDP") if Outcome == 7: print("Some cool stuff!") Inventory.append("COOL STUFF") if Outcome == 8: print("Medkit baby!") Inventory.append("MEDKIT") if Outcome > 8 and Outcome < 20: print("You trip on a rock and fall 3 feet off a small ledge") HP = HP - 5 if Outcome == 20: stuff_to_say = random.choice(Things) print(stuff_to_say) MORALE = MORALE + 30 Outcome = random.choice(DICE) if Outcome < 15: print("A soldier pops up!") print("He stabs right at you with his bayonet") print("Blood stains your shirt") HP = HP - 7 print("He then falls right down on top of you, dead as a mouse in a rat trap") if Input == "SHOOT PISTOL": Outcome = random.choice(DICE) if Outcome > 15: Kills = Kills + 1 print("You get lucky enough to blast the face of a soldier who was about to ambush you!") P_AMMO = P_AMMO - 1 else: print("Aw crap, ya hit nothing") P_AMMO = P_AMMO - 1 if Input == "SHOOT RIFLE": Outcome == random.choice(DICE) if SCOPE == 1: Outcome = Outcome +5 if Outcome > 19: print("Sniped 3 guys!") R_AMMO = R_AMMO - 3 Kills = Kills + 3 elif Outcome > 15: print("Blasted 2 soldiers!") R_AMMO = R_AMMO - 3 Kills = Kills + 3 elif Outcome > 10: print("Only got one, but I mean, thats cool") R_AMMO = R_AMMO - 3 Kills = Kills + 1 else: print("Missed every shot you n00b13!") R_AMMO = R_AMMO - 3 if Input == "SHOOT WATER GUN": print("THE ENTIRE BATTLE FIELD IS FLOODED WITH WATER") print("EVERYONE EXCEPT YOU IS NOW DEAD") Kills = 998 if Input == "INTERACT WITH": print(Inventory) Input = input("") if Input in Inventory: if Input == "PISTOL": print("Its a state of the art M1911") if Input == "RIFLE": print("Its a normal assigned Lee-Enfield Rifle") if Input == "KNIFE": print("Its a small combat knife") if Input == "BEANS": print("Some tasty beans!") print("MMMmmmm...") HUNGER = HUNGER + 45 Inventory.remove("BEANS") if Input == "RIFLE SCOPE": print("Greatly increases accuracy with the rifle") print("Time to strap it on!") SCOPE = 1 if Input == "PUDDING": print("Delicious chocolate pudding!") print("tasty...") HUNGER = HUNGER + 25 Inventory.remove("PUDDING") if Input == "WATER": print("Not the best in taste, but it'll save you'r life") print("A sip wont hurt right?") THIRST = THIRST + 80 Inventory.remove("WATER") if Input == "MEDKIT": print("Some healthy stuff, finally!") print("fixes up self") HP = HP + 15 Inventory.remove("MEDKIT") if Input == "MRE": print("Military grade ready to eat!") print("Eats") HUNGER = HUNGER + 80 Inventory.remove("MRE") if Input == "PFP": print("Processed Food Packaging") print("FINE. I'll eat it") HUNGER = HUNGER + 60 Inventory.remove("PFP") if Input == "PDP": print("Processed Drink Packaging") print("Gross! I'll take a sip") THIRST = THIRST + 60 Inventory.remove("PDP") if Input == "CRYSTAL EGG": print("HeroMourne is the sole and only creator of this game") print("Hope you like the game!") print("- HeroMourne") if Input == "READY PLAYER ONE NOVEL": print("Best thing EVA!") print("Reads") MORALE = MORALE + 100 if Input == "DS LITE": print("2nd BEST THING EVA!") print("Plays") if Input == "POKEMON DS CARTRIDGE": print("Too bad you dont have a DS to play it on") if Input == "WATER GUN": print("The holy hand grenade of guns") print("admire its skillfully machine-made plastic") print("so beautiful...") time.sleep(2) print("AND EXTREMELY DEADLY!! :D ") if Input == "CIGAR PACK": print("Very addictive and dangerous") print("This is awful for your health") MORALE = MORALE + 100 HP = HP / 5 if Input == "CHIPS": print("Tasty!") HUNGER = HUNGER + 35 Inventory.remove("CHIPS") if Input == "GUNS MAGAZINE": print("This is sooo cool!") MORALE = MORALE + MAGMOR MAGMOR = MAGMOR - 5
if Input == "COOL STUFF": COOL = random.choice(COOLSTUFF) print(COOL) print("Messes with") time.sleep(3) print("Whoops! Broke it!") MORALE = MORALE + 35 MORALE = MORALE - 10 HUNGER = HUNGER - 10 THIRST = THIRST - 10 print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print("") print(" GAME OVER ") print(Kills) print("Was how many kills you got")