Exemple #1
0
def start():
	print "-----"
	a=str(raw_input("Welcome. Would you like to begin? (Y/N/help)\n"))
	if a=="y":
		startArea.startArea()
	elif a=="n":
		print "Exiting..."
		exit()
	elif a=="help":
		print "-----"
		print '''All responses are typed using lowercase letters. Things you can interact with are generally indicated with capital letters. For example, a sentence that says, "The FLASHLIGHT is turned off, and the WALL behind it is unlit," indicates that you may interact with the flashlight and the wall. 
		
		Commands are very simple. Oftentimes just entering the capitalized word will produce results, but you can usually "look <object>" or "leave|go back." If you would like to enter a room, you can usually just type the name of that room if it is accessable from your current position.
		
		The command "info" reprints what information you were given when entering the room, while "describe" uses great detail to describe the room. ("Describe" and "info" commands not yet implemented.)'''
		start()
	elif a=="entryway":
		entryway.entryway()
	elif a=="danceroom":
		danceRoom.danceRoom()
	elif a=="corridor":
		corridor.corridor()
	elif a=="woodshop":
		woodShop.woodShop()
	elif a=="hallway1":
		hallway1.hallway1()
	else:
		print "Error. Invalid command."
		start()
Exemple #2
0
def corridor():
    if globalvariables.lightsOn == 0:
        print "-----"
        print "There's nothing much here. You feel the corridor extend to the WEST, but it is too dark for you too feel safe continuing on. However, you do notice a GLINT on the wall to the east. SOUTH of you is the entryway.\n"
        a = str(raw_input("What do you want to do?\n"))
        if a == "go back" or a == "return entryway" or a == "south":
            print "-----"
            print "You head to the ENTRYWAY."
            entryway.entryway()
        elif a == "examine glint" or a == "look glint" or a == "glint":
            glint()
        elif a == "continue" or a == "west":
            print "-----"
            print "Your gut tells you that you are likely to be eaten by a grue. You return to the slightly lighter area."
            corridor()
        else:
            print "-----"
            print "You don't think you can do that."
            corridor()
    elif globalvariables.lightsOn == 1:
        print "-----"
        print "There is a long HALLWAY to the west with many doors on either side. Nearby and also to the west is a PURPLEDOOR that you could not see in the darkness.\n"
        a = str(raw_input("What do you want to do?\n"))
        if a == "go back":
            print "-----"
            print "You turn around and head back to the ENTRYWAY."
            entryway.entryway()
        elif a == "continue" or a == "hallway":
            print "-----"
            print "You continue on a few steps, into the hallway."
            hallway1.hallway1()
        elif a == "purpledoor":
            if globalvariables.chisel == 0:
                print "-----"
                print "The purpledoor is painted shut."
                corridor()
            elif globalvariables.chisel == 1 and globalvariables.woodShopDoorOpen == 0:
                purpledoor()
            elif globalvariables.chisel == 1 and globalvariables.woodShopDoorOpen == 1:
                print "-----"
                print "You step through the purpledoor and into the WOODSHOP."
                woodShop.woodShop()
            else:
                print "Error: problem with the chisel or the woodshop door."
                corridor()
        else:
            print "-----"
            print "You don't think you can do that."
            corridor()
    else:
        print "Error: The lights are broken somehow!"