def Embark2(): print("\nSaan mentions how beautiful this planet is.") time.sleep(2) print("Seems like they all want to stick around for a bit.") time.sleep(2) print('\nLEAVE [1]') print('STAY [2]') while True: try: choose = int(input('\nACTION >> ')) if choose == 1: emb2End() if choose == 2: print('\nYou and your friends disembark.') line_ext = 1 state_ext = 2 scripts.saveWriter(line_ext, state_ext) time.sleep(3) scripts.screenClear() time.sleep(1) print('\nChapter Two complete.') time.sleep(2) scripts.screenClear() time.sleep(1) mm3.mainMenu3() if choose > 2 or choose < 0: scripts.inpErrorHandler() Embark2() except ValueError: scripts.inpErrorHandler() Embark2()
def riverMain(): while True: try: vars = scripts.savePull() has_bottle = vars[16] scripts.screenClear() scripts.versionHeader() scripts.invDisplay() print( textwrap.fill( 'Making your way over to a river, you see lots of strange grasses. The water flows peacefully.', 75)) print('\nSIT DOWN [1]') if has_bottle == 1 or has_bottle == 5: print('FILL BOTTLE [2]') if has_bottle == 4: print('DUMP WATER OUT [2]') if has_bottle == 2 or has_bottle == 0: print('DRINK WATER [2]') print('BACK [3]') choose = int(input('\nACTION >> ')) if choose == 1: riverSel1() if choose == 2: if has_bottle == 1 or has_bottle == 5: line_ext = 16 state_ext = 4 scripts.saveWriter(line_ext, state_ext) print( '\nYou scoop your bottle in the water and collect it.') time.sleep(3) riverMain() if has_bottle == 2 or has_bottle == 0: print('\nYou drink the water. It tastes sweet...') time.sleep(3) riverMain() if has_bottle == 4: line_ext = 16 state_ext = 5 scripts.saveWriter(line_ext, state_ext) print('\nYou dump the water out into the river.') time.sleep(3) riverMain() if choose == 3: print( "\nAs beautiful as the river is, there's so much more to discover." ) time.sleep(2.5) mm3.mainMenu3() if choose > 3 or choose < 1: scripts.inpErrorHandler() riverMain() except ValueError: scripts.inpErrorHandler() riverMain()
def saveLoader(): save = scripts.savePull() var2 = save[1] var14 = save[13] if var14 == 0: if var2 == 0: #Chapter 1 mm1.mainMenu1() if var2 == 1: #Chapter 2 mm2.mainMenu2() if var2 == 2: #Chapter 3 print('') print(textwrap.fill('WARNING: This chapter is NOT ready! Only proceed if you are prepared for some seriously in-progress work...', 75)) time.sleep(4) mm3.mainMenu3() if var14 == 1: mm3.mainMenu3()
def emb2Handler(): while True: try: print("Save failed.") print('\nCONTINUE [1]') print('QUIT [2]\n') choose = int(input('ACTION >> ')) if choose == 1: mm3.mainMenu3() if choose == 2: quit() if choose > 2 or choose < 0: scripts.inpErrorHandler() emb2Handler() except ValueError: scripts.inpErrorHandler() emb2Handler()
def Lizard(): while True: try: scripts.screenClear() scripts.versionHeader() scripts.invDisplay() vars = scripts.savePull() var5 = vars[4] var6 = vars[5] var7 = vars[6] var15 = vars[14] var16 = vars[15] annoyed_lizard = vars[10] print('You and your friends walk towards the lizard. ', end='') if var16 == 2: print('He waves at you all, inviting you over!') if var16 == 0 or 1 or 3: print('He notices you.') if var5 == 1 and var7 == 1: print('He looks incredibly hesistant.') print('\nTALK [1]') print('OPTION [2]') print('BACK [3]') choose = int(input('\nACTION >> ')) if choose == 1: if annoyed_lizard == 4: print('\nThe lizard mentions how strangely you acted earlier, trying to punch him.') time.sleep(4) print('...kinda awkward. You head back.') time.sleep(2) mm3.mainMenu3() if var5 == 1 and var7 == 1 and annoyed_lizard != 4: print("\nYou ask him why he looks so nervous. He can't even look at you.") time.sleep(3) print("He leaves in a hurry.") time.sleep(2) line_ext = 17 state_ext = 1 scripts.saveWriter(line_ext, state_ext) #write new var so he doesn't show up on mm3 mm3.mainMenu3() if var6 == 1 and annoyed_lizard != 4: Lizard() #shouldn't be possible if var16 == 2 and annoyed_lizard != 4: print('\nHe starts up a little chat with you guys.') print('Seems like he really appreciates your presence.') time.sleep(5) Lizard() else: print('\nThe lizard man asks you guys if you need help getting back home.') time.sleep(3) print("Kinda obvious, isn't it?") time.sleep(2) Lizard() if choose == 2: pass if choose == 3: print('\nYou all tell him that you need to go for a bit.') time.sleep(2) mm3.mainMenu3() if choose > 3 or choose < 1: scripts.inpErrorHandler() Lizard() except ValueError: scripts.inpErrorHandler() Lizard()
def devJump(): scripts.screenClear() print('\nDevelopment Hopper\n') print('CHAPTER 1 [1]') print('CHAPTER 2 [2]') print('CHAPTER 3 [3]') print('\nPROD RESET [4]') print('') print('BAD END FLAG [5]') print('TOOLS USED FLAG [6]') print('KILLED LIZARD FLAG [7]') print('SPLASH OFF [8]') print('SPLASH ON [9]') print('FLOWER [10]') print('\nEXIT [11]') while True: try: choose = int(input('\nACTION >> ')) if choose == 1: #Chapter 1 Jump mm1.mainMenu1() if choose == 2: #Chapter 2 Jump line_ext = 0 state_ext = 1 scripts.saveWriter(line_ext, state_ext) line_ext = 0 state_ext = 1 scripts.saveWriter(line_ext, state_ext) mm2.mainMenu2() if choose == 3: #Chapter 3 Jump line_ext = 0 state_ext = 1 scripts.saveWriter(line_ext, state_ext) line_ext = 1 state_ext = 2 scripts.saveWriter(line_ext, state_ext) mm3.mainMenu3() if choose == 4: #Full Reset save = open('data.txt', 'w+') save.write("0\n0\n0\n0\n0\n0\n0\n0\n0\n0\n0\n0\n0\n0\n0\n0") save.close() devJump() if choose == 5: #Bad Ending line_ext = 8 state_ext = 1 scripts.saveWriter(line_ext, state_ext) line_ext = 0 state_ext = 1 scripts.saveWriter(line_ext, state_ext) line_ext = 1 state_ext = 1 scripts.saveWriter(line_ext, state_ext) devJump() if choose == 6: #Tools used flag line_ext = 2 state_ext = 1 scripts.saveWriter(line_ext, state_ext) devJump() if choose == 7: #Lizard murder flag line_ext = 5 state_ext = 1 scripts.saveWriter(line_ext, state_ext) line_ext = 6 state_ext = 1 scripts.saveWriter(line_ext, state_ext) devJump() if choose == 8: line_ext = 10 state_ext = 1 scripts.saveWriter(line_ext, state_ext) devJump() if choose == 9: line_ext = 10 state_ext = 0 scripts.saveWriter(line_ext, state_ext) devJump() if choose == 10: line_ext = 15 state_ext = 1 scripts.saveWriter(line_ext, state_ext) if choose == 11: scripts.screenClear() quit() except ValueError: devJump()