Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Adventure in Clearwater
- # by DTALLEY11
- # Variables
- sword = 0
- player = "player"
- hometown = ('Clearwater Town', 'It is a quiet little town where '+player+' was born.')
- crossroads = ('Cross Roads', 'The point that connects Clearwater town with the bridge, fishing spot and the falls')
- goblencave = ('Clearwater Cave' , 'Hidden behind clearwater falls, the caves are infamous for constantly being Goblen Infested')
- forests = ('Great Forest' , 'The large forest outside of town')
- bridge = ('Clearwater Bridge' , 'The bridge that goes over the clearwater river')
- waterfall = ('Clearwater Falls', 'The roaring waterfall, known for concealing the Clearwater Cave')
- fishing = ('Fishing Spot', 'Everybody\'s favorite fishing location, Every local fisherman has a story about this spot')
- location = hometown
- clearwater = {
- hometown: (crossroads,),
- crossroads: (hometown, waterfall, fishing, bridge),
- waterfall: (goblencave, crossroads),
- goblencave: (waterfall,),
- fishing: (crossroads,),
- bridge: (forests, crossroads),
- forests: (bridge,)
- }
- # Events and General Functions
- # When the player ventures into the cave, this even trigures
- def caveevent(sword):
- if sword == 0:
- print "As you look at the cave, you realize that it is unwise to go into a goblen infested cave without any way to defend yourself, and decide not to venture in."
- return 0
- else:
- print "Placeholder"
- print "You are teh 1337 goblen slayer, you just WIN"
- return 1
- def ynprompt():
- yes = set(['yes','y', 'ye', ''])
- no = set(['no','n'])
- choice = raw_input(('[Y,n] ')).lower()
- if choice in yes: return 1
- elif choice in no: return 0
- else: return None
- # When the player starts the game, this intro is ran
- def intro():
- print "Hello, what is your name?\n"
- player = raw_input('Name? ')
- print player+"? That's a cool name!\n"
- print "Well, "+player+" I think it's time that you go explore the local area"
- # Main Loop
- while True:
- print "This is "+location[0]+", "+location[1]
- if location == goblencave: caveevent(sword)
- print "\nFrom "+location[0]+" you can go to these places:\n"
- for (i, t) in enumerate(clearwater[location]):
- print i +1, t[0]
- choice = int(raw_input('Where would you like to go? (Chose one) '))
- location = clearwater[location][choice - 1]
Advertisement
Add Comment
Please, Sign In to add comment