bladesoflegends


SUBMITTED BY: Guest

DATE: Nov. 29, 2013, 4:56 p.m.

FORMAT: Text only

SIZE: 2.4 kB

HITS: 694

  1. # This program will calculate experience need or gold needed to get desired amount for a game called bladesoflegends
  2. # http://bladesoflegends.com/?r=1178
  3. import time
  4. def main2():
  5. x = input("Return to main [y]es or [n]o >> ")
  6. if x == "y":
  7. main()
  8. elif x == "n":
  9. print("k")
  10. else:
  11. main2()
  12. def main():
  13. z = input('Gold [1] or Experience [2] >> ')
  14. if z == '1':
  15. gold()
  16. elif z == '2':
  17. experience()
  18. else:
  19. print('No.')
  20. time.sleep(1)
  21. main()
  22. def experience():
  23. print('\nThis will calculate how much experience and kills you need to level up.')
  24. time.sleep(0.5)
  25. totalexp = input('Total exp >> ')
  26. currentexp = input('Experience you have now >> ')
  27. expperkill = input('Experience per kill >> ')
  28. neededexp = int(totalexp) - int(currentexp)
  29. neededkills = int(neededexp) / int(expperkill)
  30. a = neededkills * 5.5
  31. b = a / 60
  32. c = b / 60
  33. d = c / 24
  34. print('\nYou need ' + str(neededexp) + ' to level up.')
  35. print('You have to kill ' + str(round(neededkills,0)) + ' creatures to level up.')
  36. print('It will take you ' + str(round(c,1)) + ' (' + str(round(d,1)) + ' days) non-stop hours to level up.')
  37. time.sleep(1)
  38. def gold():
  39. print('\nThis will calculate how much creatures you need to kill to get desired gold.')
  40. time.sleep(0.5)
  41. currentgold = int(input('\nCurrent gold >> '))
  42. desiredamount = int(input('Wanted gold >> '))
  43. goldperkill = int(input('Gold per kill >> '))
  44. neededgold = desiredamount - currentgold
  45. neededkills = neededgold / goldperkill
  46. a = neededkills * 5.5
  47. b = a / 60
  48. c = b / 60
  49. d = c / 24
  50. print('\nYou need ' + str(neededgold) + ' gold.')
  51. print('You need to kill ' + str(round(neededkills,0)) + ' creatures.')
  52. print('It will take you ' + str(round(c,1)) + ' (' + str(round(d,1)) + ' days) non-stop hours to wanted gold.')
  53. time.sleep(0.5)
  54. z = input('\nReturn to main [y]es or [n]o >> ')
  55. if z == 'y':
  56. main()
  57. else:
  58. print('k')
  59. main()

comments powered by Disqus