Ejemplo n.º 1
0
def explore():

    if floors[floor].searched == 0:
        if random.randint(1, 100) < floors[floor].danger:
            print("An enemy rushes from the darkness!")
            input("hit enter when ready --->")
            utilities.turnbump(3)
            battles.battle()
    else:
        print("You've already searched this floor!")
        input("")
        input("hit enter when ready")
Ejemplo n.º 2
0
# main game loop
while gamerun == "y":
    utilities.turnbump(2)
    print(" +++ ESCAPE THE EVIL WIZARD'S TOWER!!! +++ ")
    print(" _________________________________________")
    while action != "escape" or player.stats["health"] >= 1:
        player.xp_check(player.stats["Experience"], player.stats["Level"])
        utilities.turnbump(3)
        print("You're on the " + floors[floor].name)
        print("_________________________________________")
        print("WHATDO?")
        action = input("?")

        # Battle function tester
        if action == "battle":
            battles.battle()
        elif action == "e":
            player.stats["Experience"] += 150
        elif action == "stats":
            for key in player.stats:
                print("{0} : {1}".format(key, player.stats[key]))
            input("hit enter when ready --->")
            utilities.turnbump(21)

        elif action == "floor":
            print(str(floors[floor].name))

        elif action == "attack":
            print(player.stats["Attack"])

        elif action == "explore":