Advertisement
Guest User

Untitled

a guest
Dec 17th, 2018
145
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 28.93 KB | None | 0 0
  1. #loop so that the computer types letters individually
  2. #treasure chest find0
  3. #battling monsters
  4. #finds potions and shops
  5. #choose different classes of warrior/mage/archer/dictator
  6. #trying to save your friend
  7. import time
  8. import random
  9. import sys
  10. from os import system, name
  11. from time import sleep
  12. HP = 0
  13. DMG = 0
  14. SPD = 0
  15. RANGE = 0
  16. PERCENT = 100
  17. CLASS = 0
  18. ENEMY = 0
  19. MHP = 0
  20. Floor = 0
  21. Rooms = 0
  22. ATK_NUMBER = 0
  23. Gold = 0
  24. def clear():
  25.     if name=="nt":
  26.         _=system("cls")
  27.     else:
  28.         _=system("clear")
  29. def print1(s):
  30.     for c in s:
  31.         sys.stdout.write(c)
  32.         sys.stdout.flush()
  33.         time.sleep(0.05)
  34. #Cited from Stack Overflow due to issues with other program
  35.  
  36. def skull():
  37.     print ("███████▀▀▀░░░░░░░▀▀▀███████")
  38.     print ("██████▀░░░░░░░░░░░░░░░▀████")
  39.     print ("█████│░░░░░░░░░░░░░░░░│████")
  40.     print ("████└┐░░░░░░░░░░░░░░░┌┘░███")
  41.     print ("███░░└┐░░░░░░░░░░░░░░┌┘░░██")
  42.     print ("███░┌┘▄▄▄▄▄░░░░░▄▄▄▄▄└┐░░██")
  43.     print ("██▌░▄██████▄░░░▄██████▄░▐██")
  44.     print ("███─┘░░▓▓▓▓░░░░░▓▓▓▓░░└─███")
  45.     print ("██▀▓▓▓░▓▓▓▓░░░░░▓▓▓▓░▓▓░▀██")
  46.     print ("██▄▓▓▓░▓▓▓▓▄▄▄▄▄▓▓▓▓░▓▓▄███")
  47.     print ("████▄─┘█████████████└─▄████")
  48.     print ("█████░░▐███████████▌░░█████")
  49.     print ("██████░░▀█████████▀░░▐█████")
  50.     print ("███████░░░░▓▓▓▓▓░░░░▄██████")
  51.     print ("████████▄░░░░░░░░░▄████████")
  52. def skull2():
  53.     print ("███████▀▀▀░░░░░░░▀▀▀███████")
  54.     print ("██████▀░░░░░░░░░░░░░░░▀████")
  55.     print ("█████│░░░░░░░░░░░░░░░░│████")
  56.     print ("████└┐░░░░░░░░░░░░░░░┌┘░███")
  57.     print ("███░░└┐░░░░░░░░░░░░░░┌┘░░██")
  58.     print ("███░┌┘▄▄▄▄▄░░░░░▄▄▄▄▄└┐░░██")
  59.     print ("██▌░▄███__█▄░░░▄██__██▄░▐██")
  60.     print ("███─┘░░▓▓▓▓░░░░░▓▓▓▓░░└─███")
  61.     print ("██▀▓▓▓░▓▓▓▓░░░░░▓▓▓▓░▓▓░▀██")
  62.     print ("██▄▓▓▓░▓▓▓▓▄▄▄▄▄▓▓▓▓░▓▓▄███")
  63.     print ("██████░░▀█████████▀░░▐█████")
  64.     print ("███████░░░░▓▓▓▓▓░░░░▄██████")
  65.     print ("████████▄░░░░░░░░░▄████████")
  66.     print ("███████████████████████████")
  67.     print ("███████████████████████████")
  68.     print ("███████████████████████████")
  69. def skull_animation():
  70.     for i in range(1,20):
  71.         skull()
  72.         time.sleep(0.1)
  73.         clear()
  74.         skull2()
  75.         time.sleep(0.1)
  76.         clear()
  77.  
  78. def Warrior_info():
  79.         print1 ("The Warrior class is a class that has high Melee Damage \n")
  80.         time.sleep(2)
  81.         print1 ("The Warrior has High Healh/Armour to withstand damage \n")
  82.         time.sleep(2)
  83.         print1 ("The Warrior has a medium attack speed, so you fast players can attack you 2 times every time you attack \n")
  84.         time.sleep(2)
  85.         clear()
  86. def Mage_info():
  87.         print1("The Mage is the most magical of the 4 classes \n")
  88.         time.sleep(2)
  89.         print1("The Mage has the highest ranged damage in the game \n")
  90.         time.sleep(2)
  91.         print1("Although the mage has very low armour and attack speed in the game \n")
  92.         time.sleep(2)
  93.         print1("Being the class with the highest damage, the mage gets to attack 2 times before they engage in melee combat \n")
  94.         time.sleep(2)
  95.         print1("Once the Mage is in Melee Combat, it is very weak as it has virtually no health \n")
  96.         time.sleep(2)
  97.         clear()
  98. def Ranger_info():
  99.         print1("The Ranger is the class that is known for it's super speed \n")
  100.         time.sleep(2)
  101.         print1("The Ranger can deal a medium ammount of damage \n")
  102.         time.sleep(2)
  103.         print1("The Ranger has low health though in exchange for it's speed \n")
  104.         time.sleep(2)
  105.         print1("With the ranger being, the super fast class... it can attack 4 times before engaging in melee \n")
  106.         time.sleep(2)
  107.         print1("Once the ranger engages in melee combat,it can easily be taken down \n")
  108.         time.sleep(2)
  109.         clear()
  110. def Phsycic_info():
  111.         print1("The Phsycic is the most unique class in the game \n")
  112.         time.sleep(2)
  113.         print1("The Phsycic can either deal very high Damage or very low damage \n")
  114.         time.sleep(2)
  115.         print1("Although the Phsycic has a 50/50 chance to deal damage \n")
  116.         time.sleep(2)
  117.         print1("Although the Phsycic has a decent ammount of health, but more health than the Ranger and Mage \n")
  118.         time.sleep(2)
  119.         print1("The Phsycic has a medium range which means it can get 2 turns to attack before engaging in melee \n")
  120.         clear()
  121.        
  122. def Choose_Class_Info():
  123.     print1("There are 4 classes in this game \n")
  124.     time.sleep (1)
  125.     print1("They are: The Warrior, The Ranger, The Mage, & the Phsycic \n")
  126.     time.sleep(1)
  127.     run = True
  128.     while run:
  129.         info = input("Which class would you like to know about? (Without The), if not say no: ")
  130.         if info == "warrior" or info == "Warrior":
  131.             Warrior_info()
  132.         elif info == "Mage" or info == "mage":
  133.             Mage_info()
  134.         elif info == "Ranger" or info == "ranger":
  135.             Ranger_info()
  136.         elif info == "Phsycic" or info == "phsycic":
  137.             Phsycic_info()
  138.         elif info == "no" or info == "No":
  139.             run = False
  140.         else:
  141.             print ("Please enter a valid word not", info)
  142.             print ("You may enter the keywords: Warrior/warrior/mage/Mage/Ranger/ranger/phsycic/Phsycic")
  143.     clear()
  144. def Class_Choose():
  145.     global HP, DMG,SPD, RANGE,CLASS, PERCENT
  146.     print1("Your choices are Warrior, Mage, Ranger, or Phsycic \n")
  147.     time.sleep(1.5)
  148.     Class = input("Which Class would you like to choose?: ")
  149.     while Class != "Phsycic" and Class != "Phsycic" and Class!= "Ranger" and Class != "ranger" and Class != "Mage" and Class != "mage" and Class!= "warrior" and Class != "Warrior":
  150.         Class = input("Please Choose a valid class: ")
  151.     if Class == "warrior" or Class == "Warrior":
  152.         HP += 250
  153.         DMG += 50
  154.         SPD += 1
  155.         RANGE += 1
  156.         CLASS += 1
  157.         print1("Congratulations on selecting the Warrior Class \n")
  158.         time.sleep(1.5)
  159.         print1("It seems like you like full-on Combat \n")
  160.         time.sleep(1.5)
  161.         clear()
  162.     if Class == "Mage" or Class == "mage":
  163.         HP += 50
  164.         DMG += 100
  165.         SPD += 1
  166.         RANGE += 3
  167.         CLASS += 2
  168.         print1("Congratulations on selecting the Mage Class \n")
  169.         time.sleep(1.5)
  170.         print1("It seems like you like to do your magic \n")
  171.         time.sleep (1.5)
  172.         clear()
  173.     if Class == "Ranger" or Class == "ranger":
  174.         HP += 10
  175.         DMG += 50
  176.         SPD += 2
  177.         RANGE += 2
  178.         CLASS += 3
  179.         print1("Congratulations on selecting the Ranger Class \n")
  180.         time.sleep(1.5)
  181.         print1("It seems like, you like to be very speeedy \n")
  182.         time.sleep(1.5)
  183.         clear()
  184.     if Class == "Phsycic" or Class == "Phsycic":
  185.         HP += 100
  186.         DMG += 200
  187.         SPD += 1
  188.         RANGE += 2
  189.         PERCENT -= 50
  190.         CLASS += 4
  191.         print1("Congratualtions on selecting the Phsycic Class \n")
  192.         time.sleep (1.5)
  193.         print1("It seems like you have a very strong and intelegent mind \n")
  194.         time.sleep(1.5)
  195.         clear()
  196. def stats():
  197.     global HP, DMG,SPD, RANGE,CLASS, PERCENT
  198.     stats_ask = input("Would you like to know your stats?: ")
  199.     if stats_ask == "yes" or stats_ask == "Yes":
  200.         print1("You have " +str(HP) +" Health Points \n")
  201.         time.sleep(1)
  202.         print1("You have " +str(DMG) +" Damage \n")
  203.         time.sleep(1)
  204.         print1("You have a range of " + str(RANGE) + " \n")
  205.         time.sleep(1)
  206.         if CLASS == 3:
  207.             print1("You have super fast speed as the ranger")
  208.         else:
  209.             print1("Your speed is hit to hit on the enemy")
  210.         if PERCENT != 100:
  211.             print1("You are a Phsycic which means you have a 50/50 chance of attacking \n")
  212.             time.sleep(1.5)
  213.             print1("If your not a Phsycic, then you have bugged the game \n")
  214.         print ("You have ",Gold, "Gold to spend in the shop \n")
  215.     else:
  216.         print1("Enjoy not knowing your stats \n")
  217.         time.sleep (1.5)
  218. def Mode():
  219.     global HP, Floor, Rooms
  220.     print1("There are 4 modes to this game\n")
  221.     time.sleep(1)
  222.     print1("You have Easy mode which is 3 floors with 4 rooms each\n")
  223.     time.sleep(1)
  224.     print1("You have Medium mode with 4 floors  and 6 rooms each\n")
  225.     time.sleep(1)
  226.     print1("You have Hard mode if you want a challenge with 6 floors and 8 rooms each\n")
  227.     time.sleep(1)
  228.     print1("Finally you have insane mode if you think you are a god at this game\n")
  229.     time.sleep(1)
  230.     Mode1 = input("Which mode would you like to play on?: ")
  231.     if Mode1[0] == "E" or Mode1[0] == "e":
  232.         print1("Welcome to the easy mode, this mode is usually for new players \n")
  233.         Floor += 3
  234.         Rooms += 4
  235.         time.sleep(1)
  236.         clear()
  237.     if Mode1[0] == "M" or Mode1[0] == "m":
  238.         print1("Welcome to Medium mode, it looks like you have a bit of experience in the game \n")
  239.         Floor += 4
  240.         Rooms += 6
  241.         time.sleep(1)
  242.         clear()
  243.     if Mode1[0] == "H" or Mode1[0] == "h":
  244.         print1("It seems like you have liked to give yourself a challenge with the HARD MODE! \n")
  245.         Floor += 6
  246.         Rooms += 8
  247.         time.sleep(1)
  248.         clear()
  249.     if Mode1[0] == "I" or Mode1[0] == "i":
  250.         print1("Welcome to INSANE MODEEE!, Prepare to be stuck inside a time rift \n")
  251.         Floor += 20
  252.         Rooms += 10
  253.         time.sleep(1)
  254.         clear()
  255. def Fight(i):
  256.     global HP, DMG,SPD, RANGE,CLASS, ATKD, ATK_NUMBER, ENEMY
  257.     while i > 0:
  258.         if CLASS == 1 or CLASS == 2 or CLASS == 3:
  259.             for i in range(RANGE - 2):
  260.                 ATK11 = random.randint(1,2)
  261.                 ATK1 = int(input("Choose a number between 1 and 2: "))
  262.                 if ATK11 == ATK1 and CLASS == 1:
  263.                     i -= DMG
  264.                     print ("You have dealt a good magical sword hit of", DMG, "magical damage, your Enemy has:", i ,"HP")
  265.                 elif ATK11 != ATK1 and CLASS == 1:
  266.                     i -= (DMG/2)
  267.                     print ("Your magical sword has barely hit your enemy of:", (DMG/2), "damage, your Enemy has:", i, "HP")
  268.                 elif ATK11 == ATK1 and CLASS == 2:
  269.                     i -= DMG
  270.                     print ("You have dealt a good mage shot to your enemy and have dealt:", DMG, "magical damage, your Enemy has:", i ,"HP")
  271.                 elif ATK11 != ATK1 and CLASS == 2:
  272.                     i -= (DMG/2)
  273.                     print ("You shot a fireball at the enemy but merely skimmed him and have dealt:", (DMG/2), "damage, your Enemy has:", i, "HP")
  274.                 elif ATK11 == ATK1 and CLASS == 3:
  275.                     i -= DMG
  276.                     print ("You have your crossbow at your enemy and have dealt:", DMG, "ranged damage, your Enemy has:", i ,"HP")
  277.                 elif ATK11 != ATK1 and CLASS == 3:
  278.                     i -= (DMG/2)
  279.                     print ("You attempt to shoot your enemy and have barely dealt:", (DMG/2), "ranged damage, your enemy has:", i, "HP")
  280.             else:
  281.                 ATK11 = random.randint(1,2)
  282.                 ATK1 = int(input("Choose a number between 1 and 2: "))
  283.                 if ATK1 == 1:
  284.                     ATK_NUMBER = 1
  285.                 elif ATK1 == 2:
  286.                     ATK_NUMBER = 2
  287.                 if ATK11 == ATK_NUMBER and CLASS == 1:
  288.                     i -= DMG
  289.                     print ("You have dealt a good sword blow to the enemy and have dealt:", DMG, "damage, your Enemy has:", i ,"HP")
  290.                 elif ATK11 != ATK_NUMBER and CLASS == 1:
  291.                     i -= (DMG/2)
  292.                     print ("You swung at the enemy but didn't get a good hit on him and you have dealt:", (DMG/2), "damage, your Enemy has:", i, "HP")
  293.                 elif ATK11 == ATK1 and CLASS == 2:
  294.                     i -= DMG
  295.                     print ("You have dealt a good mage shot to your enemy and have dealt:", DMG, "magical damage, your Enemy has:", i ,"HP")
  296.                 elif ATK11 == ATK1 and CLASS == 2:
  297.                     i -= (DMG/2)
  298.                     print ("You shot a fireball at the enemy but merely skimmed him and have dealt:", (DMG/2), "damage, your Enemy has:", i, "HP")
  299.                 elif ATK11 == ATK1 and CLASS == 3:
  300.                     i -= DMG
  301.                     print("You have dealt a good Ranger slice to your enemy and have dealt:", DMG, "quick damage, your Enemy has:", i ,"HP")
  302.                 elif ATK11 != ATK1 and CLASS == 3:
  303.                     i -= (DMG/2)
  304.                     print ("You attempt to slice your enemy again and have barely dealt:", (DMG/2), "quick damage, your enemy has:", i, "HP")
  305.                     ATK1 = (input("Choose a number between 1 and 2: "))
  306.                 elif ATK11 == ATK1 and CLASS == 3:
  307.                     i -= DMG
  308.                     print ("You have dealt a good Ranger slice to your enemy and have dealt:", DMG, "quick damage, your Enemy has:", i ,"HP")
  309.                 elif ATK11 != ATK1 and CLASS == 3:
  310.                     i -= (DMG/2)
  311.                     print ("You attempt to slice your enemy again and have barely dealt:", (DMG/2), "quick damage, your enemy has:", i, "HP")
  312.                 else:
  313.                     HP += 0
  314.                 ATKD = random.randint (1,ENEMY)
  315.                 print1("Your Enemy is preparing to attack you \n")
  316.                 time.sleep(3)
  317.                 ATKP = random.randint(1,3)
  318.                 if ATKP == 3 and CLASS == 1:
  319.                     print ("You have dodged your enemy and he has mist")
  320.                 elif ATKP == 2 and CLASS == 1:
  321.                     HP -= ATKD
  322.                     print ("Your Enemy has dealt a good blow to you", str(ATKD),"Damage to you, you have", HP, "Health.")
  323.                 elif ATKP == 1 and CLASS == 1:
  324.                     HP -= (ATKD//2)
  325.                     print ("Your Enemy has dealt a weak blow to you of",str(ATKD//2),"Damage to you, you have", HP, "Health.")
  326.                 elif ATKP == 3 and CLASS == 2:
  327.                     print ("You have dodged your enemy and he has mist")
  328.                 elif ATKP == 2 and CLASS == 2:
  329.                     HP -= ATKD
  330.                     print ("Your Enemy has dealt a good blow of", ATKD,"damage to you, you have", HP, "Health.")
  331.                 elif ATKP == 1 and CLASS == 2:
  332.                     HP -= (ATKD*2)
  333.                     print ("Your Enemy has dealt a Devasting blow of",ATKD * 2,"Damage to you, you have", HP, "Health.")
  334.                 elif ATKP == 3 and CLASS == 3:
  335.                     print ("You have dodged your enemy and he has mist")
  336.                 elif ATKP == 2 and CLASS == 3:
  337.                     HP -= (ATKD//5)
  338.                     print ("Your Enemy has dealt a very weak blow of", ATKD//5,"damage to you, you have", HP, "Health.")
  339.                 elif ATKP == 1 and CLASS == 3:
  340.                     HP -= (ATKD*3)
  341.                     print ("Your Enemy has dealt a Destroying blow of",ATKD * 3,"Damage to you, you have", HP, "Health.")
  342.                 if HP <= 0 and CLASS == 1:
  343.                     print("You have faithfully died a warrior's death trying to save your friend, please restart the game")
  344.                     exit()
  345.                 elif HP < 0 and CLASS == 2:
  346.                     print("It looks like your magic couldn't save you, you've enter magical heaven... please restart the game")
  347.                     exit()
  348.                 elif HP < 0 and CLASS == 3:
  349.                     print("It looks like your speed wasn't enough to save you, you have died a quick death, please restart the game")
  350.                     exit()
  351.                 else:
  352.                     HP+=0
  353.         clear()
  354. #       if CLASS == 2:
  355. #           for i in range(RANGE - 2):
  356. #               ATK11 = random.randint(1,2)
  357. #               ATK1 = int(input("Choose a number between 1 and 2: "))
  358. #               if ATK11 == ATK1:
  359. #                   i -= DMG
  360. #                   print ("You have dealt a good mage shot to your enemy and have dealt:", DMG, "magical damage, your Enemy has:", i ,"HP")
  361. #               else:
  362. #                   i -= (DMG/2)
  363. #                   print ("You shot a fireball at the enemy but merely skimmed him and have dealt:", (DMG/2), "damage, your Enemy has:", i, "HP")
  364. #           else:
  365. #               ATK11 = random.randint(1,2)
  366. #               ATK1 = (input("Choose a number between 1 and 2: "))
  367. #               if ATK1 == 1:
  368. #                   ATK_NUMBER = 1
  369. #               elif ATK1 == 2:
  370. #                   ATK_NUMBER = 2
  371. #               if ATK11 == ATK1:
  372. #                   i -= DMG
  373. #                   print ("You have dealt a good mage shot to your enemy and have dealt:", DMG, "magical damage, your Enemy has:", i ,"HP")
  374. #               else:
  375. #                   i -= (DMG/2)
  376. #                   print ("You shot a fireball at the enemy but merely skimmed him and have dealt:", (DMG/2), "damage, your Enemy has:", i, "HP")
  377. #               ATKD = random.randint (1,ENEMY)
  378. #               print1("Your Enemy is preparing to attack you \n")
  379. #               time.sleep(4)
  380. #               ATKP = random.randint(1,3)
  381. #               if ATKP == 3:
  382. #                   print ("You have dodged your enemy and he has mist")
  383. #               if ATKP == 2:
  384. #                   HP -= ATKD
  385. #                   print ("Your Enemy has dealt a good blow of", ATKD,"damage to you, you have", HP, "Health.")
  386. #               if ATKP == 1:
  387. #                   HP -= (ATKD*2)
  388. #                   print ("Your Enemy has dealt a Devasting blow of",ATKD * 2,"Damage to you, you have", HP, "Health.")
  389. #               if HP < 0:
  390. #                   print("It looks like your magic couldn't save you, you've enter magical heaven... please restart the game")
  391. #                   exit()
  392. #       if CLASS == 3: 
  393. #           for i in range(RANGE - 2):
  394. #               ATK11 = random.randint(1,2)
  395. #               ATK1 = int(input("Choose a number between 1 and 2: "))
  396. #               if ATK11 == ATK1:
  397. #                   i -= DMG
  398. #                   print ("You have your crossbow at your enemy and have dealt:", DMG, "ranged damage, your Enemy has:", i ,"HP")
  399. #               else:
  400. #                   i -= (DMG/2)
  401. #                   print ("You attempt to shoot your enemy and have barely dealt:", (DMG/2), "ranged damage, your enemy has:", i, "HP")
  402. #           else:
  403. #               ATK11 = random.randint(1,2)
  404. #               ATK1 = int(input("Choose a number between 1 and 2: "))
  405. #               if ATK11 == ATK1:
  406. #                   i -= DMG
  407. #                   print("You have dealt a good Ranger slice to your enemy and have dealt:", DMG, "quick damage, your Enemy has:", i ,"HP")
  408. #               else:
  409. #                   i -= (DMG/2)
  410. #                   print ("You attempt to slice your enemy again and have barely dealt:", (DMG/2), "quick damage, your enemy has:", i, "HP")
  411. #               ATK1 = (input("Choose a number between 1 and 2: "))
  412. #               if ATK11 == ATK1:
  413. #                   i -= DMG
  414. #                   print ("You have dealt a good Ranger slice to your enemy and have dealt:", DMG, "quick damage, your Enemy has:", i ,"HP")
  415. #               else:
  416. #                   i -= (DMG/2)
  417. #                   print ("You attempt to slice your enemy again and have barely dealt:", (DMG/2), "quick damage, your enemy has:", i, "HP")
  418. #               ATKD = random.randint (1,ENEMY)
  419. #               print1("Your Enemy is preparing to attack you \n")
  420. #               time.sleep(4)
  421. #               ATKP = random.randint(1,3)
  422. #               if ATKP == 3:
  423. #                   print ("You have dodged your enemy and he has mist")
  424. #               if ATKP == 2:
  425. #                   HP -= (ATKD//5)
  426. #                   print ("Your Enemy has dealt a very weak blow of", ATKD//5,"damage to you, you have", HP, "Health.")
  427. #               if ATKP == 1:
  428. #                   HP -= (ATKD*3)
  429. #                   print ("Your Enemy has dealt a Destroying blow of",ATKD * 3,"Damage to you, you have", HP, "Health.")
  430. #               if HP < 0:
  431. #                   print("It looks like your speed wasn't enough to save you, you have died a quick death, please restart the game")
  432. #                   exit()
  433.         if CLASS == 4:
  434.             ATK11 = random.randint(1,2)
  435.             ATK1 = int(input("Choose a number between 1 and 2: "))
  436.             if ATK1 == 1:
  437.                 ATK_NUMBER = 1
  438.             elif ATK1 == 2:
  439.                 ATK_NUMBER = 2
  440.             if ATK11 == ATK_NUMBER:
  441.                 i -= DMG
  442.                 print ("You have tried to control your enemies mind and have dealt:", DMG, " mind damage, your Enemy has:", i ,"HP")
  443.             elif ATK11 != ATK_NUMBER:
  444.                 print ("You have tried to control your enemy but he has a strong mind and you have deal no damage, your Enemy has:", i, "HP")
  445.             ATKD = random.randint (1,ENEMY)
  446.             print1("Your Enemy is preparing to attack you \n")
  447.             time.sleep(3)
  448.             ATKP = random.randint(1,3)
  449.             if ATKP == 3:
  450.                 print ("You have stopped your enemy with your mind")
  451.             if ATKP == 2:
  452.                 HP -= ATKD
  453.                 print ("Your Enemy has dealt a great blow to your weak body of of", str(ATKD),"Damage to you, you have", HP, "Health.")
  454.             if ATKP == 1:
  455.                 HP -= (ATKD//2)
  456.                 print ("Your Enemy has dealt a weak blow to you of",str(ATKD//2),"Damage to you, you have", HP, "Health, but it still hurts.")
  457.             if HP <= 0:
  458.                 print("It turns out your enemie's mind was too strong and has resisted your controlling powers")
  459.                 exit()
  460.     print1("It turns out that you have defeated your enemy well enough, great job! \n")
  461.  
  462. def Monster_Dungeon1():
  463.     global HP, DMG,SPD, RANGE,CLASS, ENEMY
  464.     print ("You enter a Dark Scary Dungeon \n")
  465.     time.sleep(1.5)
  466.     clear()
  467.     print ("You hear a scary sound Snarling in the dungeon \n")
  468.     time.sleep(1.5)
  469.     clear()
  470.     Go_On = input("Would you like to go on?: ")
  471.     if Go_On == "Yes" or Go_On == "yes":
  472.         print ("You continue on to enter through the room \n")
  473.     else:
  474.         print ("You try to move away but your instincts tell you to move on")
  475.     time.sleep(1.5)
  476.     clear()
  477.     print ("You then hear a Dark Loud Growl")
  478.     time.sleep(1.5)
  479.     clear()
  480.     print ("A Big Brown Fuzzy Animal jumps out")
  481.     time.sleep (2)
  482.     clear()
  483.     print ("You see that it's an undead bear with red eyes")
  484.     time.sleep (2)
  485.     clear()
  486.     print ("You notice it's bones sticking out with flys flying around")
  487.     time.sleep (1.5)
  488.     clear()
  489.     print ("The Bear Challenges You now")
  490.     time.sleep (1.5)
  491.     clear()
  492.     Wanna_Fight = input("Would you like to run away?: ")
  493.     thrown = random.randint (1,20)
  494.     if Wanna_Fight[0] == "n" or Wanna_Fight[0] == "N":
  495.         print ("You draw your weapon to fight the bear!")
  496.     else:
  497.         print ("You begin to turn and run")
  498.         time.sleep (1.5)
  499.         clear()
  500.         print ("You feel a fuzzy sharp thing grab your back")
  501.         time.sleep (1)
  502.         clear()
  503.         print ("You see the bear grab onto you and throw you into a corner")
  504.         time.sleep (0.5)
  505.         clear()
  506.         HP -= thrown
  507.         print ("You have taken",thrown, "Damage from being thrown")
  508.     ENEMY += 100
  509.     Fight(400)
  510. def Monster_Dungeon2():
  511.     global HP, DMG,SPD, RANGE,CLASS, ENEMY
  512.     print1("You enter through a dark and scary door \n")
  513.     time.sleep(1)
  514.     clear()
  515.     print1("Something about this room doesn't feel right to you \n")
  516.     time.sleep(1)
  517.     clear()
  518.     go = input("Are you too scared and want to hide? If not, say no: ")
  519.     if go[0] == "n" or go [0] == "N":
  520.         print1 ("You tell yourself that your are ready for whatever is in here and face your fears \n")
  521.         time.sleep(1)
  522.         clear()
  523.     else:
  524.         print1("You try to move around in the darkness \n")
  525.         time.sleep(1)
  526.         clear()
  527.         print1("You find something solid \n")
  528.         time.sleep(1)
  529.         clear()
  530.         print1("You attempt to hide under the object \n")
  531.         time.sleep(1)
  532.         clear()
  533.         print1("You then feel a some bone-like items \n")
  534.         time.sleep(1)
  535.         clear()
  536.         print1("You realize that you are in a monster's den \n")
  537.         time.sleep(1)
  538.         clear()
  539.         print1("You scream and run! as the sight frightens you \n")
  540.     print1("You continue to move on through the room \n")
  541.     time.sleep(1)
  542.     clear()
  543.     print1("A wind blows past your face \n")
  544.     time.sleep(1)
  545.     clear()
  546.     print1("You see that in front of you is a ghost \n")
  547.     time.sleep(1)
  548.     clear()
  549.     print1("You are forced to fight the ghost and draw your weapon")
  550.     ENEMY += 50
  551.     Fight(120)
  552. def Monster_Dungeon3():
  553.     print1("You enter through the door to see a group of goblins \n")
  554.     time.sleep(1)
  555.     clear()
  556.     print1("You also see that they hold a hostage \n")
  557.     time.sleep(1)
  558.     clear()
  559.     print1("1 of the Goblins apparently comes over and draws their weapon to fight you \n")
  560.     time.sleep(1)
  561.     clear()
  562.     print1("You prepare to fight your enemy \n")
  563.     ENEMY += 25
  564.     Fight(75)
  565.     print1("It seems like you easily defeated the goblin \n")
  566.     time.sleep(1)
  567.     clear()
  568.     print1("You found 50 gold on the goblin \n")
  569.     Gold += 50
  570.     time.sleep(1)
  571.     clear()
  572.     print1("You see that the goblin continues to torture the prisoner \n")
  573.     time.sleep(1)
  574.     clear()
  575.     print1("Another 2 goblins comes over to attack you \n")
  576.     time.sleep(1)
  577.     clear()
  578.     print1("You kill them quickly in 2 succesful hits \n")
  579.     time.sleep(1)
  580.     clear()
  581.     print1("You see that the big goblin now comes to fight you \n")
  582.     ENEMY == 50
  583.     Fight(150)
  584.     print1("Congratulations on defeating the boss Goblin \n")
  585.     time.sleep(1)
  586.     clear()
  587.     print1("The other goblins then run away as they see you killed their leader \n")
  588.     time.sleep(1)
  589.     clear()
  590.     print1("You go up and take the mask off the hostage \n")
  591.     time.sleep(1)
  592.     clear()
  593.     print1("You see that the hostage cannot be saved, but he does tell you one thing... \n")
  594.     time.sleep(1)
  595.     clear()
  596.     print1("He tells you, don't go on, he was an adventurer trying to get in but got captured \n")
  597.     time.sleep(1)
  598.     clear()
  599.    
  600. def Monster_Dungeon4():
  601.     global HP, Gold
  602.     print1("You enter through the door to find a torch lit \n")
  603.     time.sleep(1)
  604.     clear()
  605.     print1("Your eyes then adjust to what you see \n")
  606.     time.sleep(1)
  607.     clear()
  608.     print1("There, sitting on a throne of swords is a medieval armoured figure \n")
  609.     time.sleep(1)
  610.     clear()
  611.     print1("You then start to hear a rumbling sound from the ground \n")
  612.     time.sleep(1)
  613.     clear()
  614.     print1("You watch marvelously as the Medieval knight rises from his seat \n")
  615.     time.sleep(1)
  616.     clear()
  617.     print1("The Medieval Knight then bellows to you... \n")
  618.     print1("Hello Traveller, I am a Knight of this tower, and I challenge you to a duel with me, if not, I get to drain half of spirit(health)  \n")
  619.     duel = input("Do you fight the Knight of the tower?: ")
  620.     if duel[0] == "n" or duel[0] == "N":
  621.         HP/2
  622.     else:
  623.         ENEMY = 100
  624.         Fight(200)
  625.         print1("Congratulations on defeating the Knight \n")
  626.         time.sleep(1)
  627.         extra_gold = random.randint (50,100)
  628.         print ("You have found", extra_gold, "gold from the knight")
  629.         Gold+= extra_gold
  630.         print1("You move on through the next door to see what await's you")
  631.         time.sleep(1)
  632.         clear()
  633. def Monster_Dungeon5():
  634.     print1("You prepare yourself to enter the next door")
  635.     time.sleep(1)
  636.     print1("h")
  637.        
  638.    
  639. def LuckyFind():
  640.     global HP, DMG, RANGE
  641.     LUCKY_FIND = ["a Health Potion", "a Weapon Upgrade", "a Ranged weapon","Nothing", "some Gold"]
  642.     NumberFind = random.randint (0,4)
  643.     print1 ("You enter a dark room \n")
  644.     time.sleep(1)
  645.     print1 ("You see the door ahead \n")
  646.     time.sleep(1)
  647.     run = input("Would you like to go to light the room up? If not, say no and you move on: ")
  648.     if run[0] == "y" or run[0] == "Y":
  649.         find = LUCKY_FIND[NumberFind]
  650.         print("You prepare to light the room up...")
  651.         time.sleep(1)
  652.         print("You light the room up!")
  653.         time.sleep(1)
  654.         print("You find:",find)
  655.         time.sleep(1.5)
  656.         find = "a Weapon Upgrade"
  657.         if find == "a Health Potion":
  658.             e = random.randint(50,150)
  659.             HP += e
  660.             print ("You have found" , e , "Health in the health potion")
  661.         if find == "a Weapon Upgrade":
  662.             e = random.randint(25,75)
  663.             DMG += e
  664.             print ("You have found enough tools to give you" , e , "upgrade in your weapon")
  665.         if find == "a Ranged Weapon":
  666.             e = random.randint(0,1)
  667.             RANGE += e
  668.             if e > 1:
  669.                 print ("You have found a ranged weapon that allows you to have" , e , "extra range.")  
  670.             else:
  671.                 print ("You already have this ranged weapon sorry... :(")
  672.         if find == "some Gold":
  673.             e = random.randint(50,150)
  674.             Gold += e
  675.             print ("You have found" , Gold , "Gold in the Gold Bundle")
  676.         if find == "Nothing":
  677.             print1("You have found nothing, the chest had already been looted by a previous adventurer")
  678.     else:
  679.         print("You exit the room not knowing what was in there")
  680.  
  681. def Treasure_Find():
  682. #   print1("You enter a bright room \n")
  683. #   time.sleep(1)
  684. #   print1("As your eyes clear, you see a figure \n")
  685. #   time.sleep(1)
  686. #   print1("You see a room that seems dusty and empty \n")
  687. #   time.sleep(1)
  688. #   print1("Except for that old parchment that looks interesting on the table\n")
  689.     Parchment = input("Do you take a look at the parchment?: ")
  690.     if Parchment[0] == "y" or Parchment[0] == "Y":
  691.         find_time = random.randint(10,25)
  692. #       print1 ("You go to take a closer look at the parchment \n")
  693. #       time.sleep(1)
  694. #       print1("It tells you that there is a hidden treasure in this room \n")
  695. #       time.sleep(1)
  696. #       print1("You move on to find the hidden treasure \n")
  697. #       time.sleep(1)
  698. #       print1("It tells you there is one condition though \n")
  699. #       time.sleep(1)
  700. #       print1("You have:", time, "seconds to find the treasure \n")
  701. #       time.sleep(1)
  702. #       print1("Look for the first dollar sign, in the line and say the position of it in numbers")
  703.         random_letters = "QWERTYUIOPASDFGHJKLZXCVBNMqwertyuiopasdfghjklzxcvbn<>/?:;[]{}-_=+$"
  704.         password = ""
  705.         for i in range(300):
  706.             Number = random.randint(1,65)
  707.             password +=(random.choice(random_letters))
  708.         print (password)
  709.         dollar = password.find("$")
  710.         dollar_find = int(input("Enter the number position of the $ sign: "))
  711.         if dollar_find == dollar:
  712.             Gold += (random.randint(100,150))
  713.         else:
  714.             ("Y")
  715.                
  716. #           password += random_letters[random.randint(0,len(random_letters-1))]
  717.     if Parchment[0] in ["n", "N"]:
  718.         print1("You go on to the next room not knowing what the parchment said")
  719.         time.sleep(1)
  720.         print1("You prepare to move on to the next door")
  721. def Level():
  722.     global Floor, Rooms
  723.     for i in range(Floor):
  724.         for i in range (Rooms):
  725.             List_Rooms = [Monster_Dungeon1, Monster_Dungeon2, Monster_Dungeon3, Monster_Dungeon4, Monster_Dungeon5, LuckyFind, Treasure_Find]
  726.             random.choice (List_Rooms)()
  727.        
  728. f = input("Enter your Best Friend's Name: ")
  729. Saving_Friend = input("Would you like to save " + f + "?: ")
  730. if Saving_Friend[0] == "n" or Saving_Friend[0] == "N":
  731.     print1("You win the Game, because your friend turned out to be horrible \n")
  732. elif Saving_Friend[0] == "m":
  733.     print1("You lose because you can't make decisions on your own \n")
  734. else:
  735.     print1("You are a brave person trying to save your friend \n")
  736.     time.sleep (1)
  737.     print1("It looks like your are a very courageous friend \n")
  738.     time.sleep (1)
  739.     print1("Welcome to The Dungeon Heros! \n")
  740.     time.sleep(0.5)
  741.     skull_animation()
  742.     Choose_Class_Info()
  743.     Class_Choose()
  744.     stats()
  745.     Mode()
  746.     Level()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement