eahil

rooms.py

Apr 15th, 2013
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 2.43 KB | None | 0 0
  1. king like that.Then with the sagging .... No body wants to see your drawls! So that's my opinion. ######## Unpacking #######
  2. import random
  3. from sys import exit
  4.  
  5. ######## Functional Modules ######
  6.  
  7. def dead():
  8.    print("\n" + "-" * 40 + "\n")
  9.    exit("You died.\n\n" + ("-" * 40))
  10.  
  11. def next_of_set():
  12.    dying = ["You don't go forward, stumble around, fall on a knife, and die.", "You wander around the room until you starve to death.", "A bunch of bugs come down from the vent, and eat you alive."]
  13.    print("You go on to the next room\n")
  14.    print("(O)pen the door; (D)on't go forward")
  15.    next = input("> ")
  16.    if next == "O" or next == "o":
  17.        print("You open the door.")
  18.    elif next == "D" or next == "d":
  19.        print(random.choice(dying))
  20.        dead()
  21.  
  22.  
  23.  
  24. ######## Red Set #########
  25.  
  26. def goldroom():
  27.    print("You are in a gold room.")
  28.    print("How much gold do you take?")
  29.    print("1 > ~")
  30.    choose = input("> ")    
  31.    if choose >= "50":
  32.        print("Your gold is really copper, and you get stabbed trying to sell it later.")
  33.        dead()
  34.    elif choose < "50":
  35.        print("Gold is high on the market, so you get a lot of money per nugget!")
  36.    else:
  37.        print("Pick a number next time.")
  38.  
  39. def waterbox():
  40.    print("The door behind you slams shut and you have no choice but to try and hold you breath. The room is filling with water from a pipe on the side of the room. It's big enough for you to wrap your hands around it. Do you: ")
  41.    print("\n(S)wim to the top and try and hold out?")
  42.    print("\n(T)ry and hold the water in the pipe back?")
  43.    print("\nSink to the (B)ottom and just let yourself die?")
  44.    choose = input("> ")    
  45.  
  46.    if choose == "S":
  47.        print("You swim to the top but eventually run out of air.")
  48.        dead()
  49.    elif choose == "T":
  50.        print("Suddenly you realize that the water isn't water but acid and you are chemically burn to death.")
  51.        dead()
  52.    elif choose == "B":
  53.        print("A latch opens up and sucks you inside, you escape the room and surface in a pool by another one.")
  54.    else:
  55.        print("You drowned, you stupid monkey!")
  56.        dead()
  57.  
  58. def painroom():
  59.    pass
  60.  
  61. def redset():
  62.    goldroom()
  63.    next_of_set()
  64.    waterbox()
  65.    next_of_set()
  66.    painroom()
  67.  
  68. ######## Green Set ########
  69. ######## White Set ########
  70. ######## Black Set ########
  71. ######## Blood Set ########
  72. ######## Fire Set  ########
Advertisement
Add Comment
Please, Sign In to add comment