Advertisement
Guest User

Untitled

a guest
Nov 9th, 2012
95
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. while true do
  2.  
  3. --** variables to move everything around if needed **--
  4.  
  5. x = -1
  6. y = 0
  7.  
  8.  
  9.  
  10. --** design **--
  11. -- box
  12. gui.opacity(0.77)
  13. gui.drawbox(5+x, -2+y, 177+x ,26+y, "#1c1c1c")
  14.  
  15. -- mushroom graphic
  16. gui.drawline(10+x,2+y ,14+x,2+y, "red")
  17. gui.drawline(9+x,3+y ,15+x,3+y, "red")
  18. gui.drawline(9+x,4+y ,15+x,4+y, "red")
  19. gui.drawline(11+x,5+y, 13+x,5+y, "#F5D0A9")
  20. gui.drawline(11+x,6+y, 13+x,6+y, "#F5D0A9")
  21. gui.drawpixel(10+x,3+y, "white")
  22. gui.drawpixel(12+x,2+y, "white")
  23. gui.drawpixel(14+x,3+y, "white")
  24.  
  25. -- nut graphic
  26. gui.drawline(10+x, 8+y, 12+x, 8+y, "#FFCC66")
  27. gui.drawline(9+x, 9+y, 13+x, 9+y, "#FFCC66")
  28. gui.drawline(9+x, 10+y, 14+x, 10+y, "#FFCC66")
  29. gui.drawline(12+x, 11+y, 14+x, 11+y, "#FFCC66")
  30. gui.drawline(13+x, 12+y, 14+x, 12+y, "#FFCC66")
  31.  
  32. -- syrup graphic
  33. gui.drawline(11+x, 14+y, 12+x, 14+y, "#FF9900")
  34. gui.drawline(11+x, 15+y, 12+x, 15+y, "#FF9900")
  35. gui.drawline(9+x, 16+y, 14+x, 16+y, "#FF9900")
  36. gui.drawline(9+x, 17+y, 14+x, 17+y, "#FF9900")
  37. gui.drawline(10+x, 18+y, 13+x, 18+y, "#FF9900")
  38.  
  39. -- seperation line
  40. gui.opacity(0.5)
  41. gui.drawline(55+x, 1+y, 55+x, 18+y, "#FFFFFF")
  42. gui.drawline(78+x, 1+y, 78+x, 18+y, "#FFFFFF")
  43. gui.drawline(144+x, 1+y, 144+x, 25+y, "#FFFFFF")
  44. gui.opacity(0.77)
  45.  
  46. --** ADDRESS VALUES **--
  47. mushrooms = memory.readbytesigned(0x020048e2)
  48. supermushrooms = memory.readbytesigned(0x020048e3)
  49. ultramushrooms = memory.readbytesigned(0x020048e4)
  50. maxmushrooms = memory.readbytesigned(0x020048e5)
  51. nuts = memory.readbytesigned(0x020048e6)
  52. supernuts = memory.readbytesigned(0x020048e7)
  53. ultranuts = memory.readbytesigned(0x020048e8)
  54. maxnuts = memory.readbytesigned(0x020048e9)
  55. syrups = memory.readbytesigned(0x020048ea)
  56. supersyrups = memory.readbytesigned(0x020048eb)
  57. ultrasyrups = memory.readbytesigned(0x020048ec)
  58. maxsyrups = memory.readbytesigned(0x020048ed)
  59. ONEups = memory.readbytesigned(0x020048ee)
  60. ONEupDXs = memory.readbytesigned(0x020048ef)
  61. goldmushrooms = memory.readbytesigned(0x020048f0)
  62. herbs = memory.readbytesigned(0x020048f1)
  63. redpeppers = memory.readbytesigned(0x020048f2)
  64. greenpeppers = memory.readbytesigned(0x020048f3)
  65. ahastraights = memory.readbytesigned(0x020048f4)
  66. ufustraights = memory.readbytesigned(0x020048f5)
  67. gerastraights = memory.readbytesigned(0x020048f6)
  68. dehestraights = memory.readbytesigned(0x020048f7)
  69. ufumanjaros = memory.readbytesigned(0x020048f8)
  70. gerapuccinos = memory.readbytesigned(0x020048f9)
  71. dehepressos = memory.readbytesigned(0x020048fa)
  72.  
  73. ahabeans = memory.readbyte(0x02004902)
  74. ufubeans = memory.readbyte(0x02004903)
  75. gerabeans = memory.readbyte(0x02004904)
  76. dehebeans = memory.readbyte(0x02004905)
  77.  
  78.  
  79.  
  80. --TODO: CLOTHES
  81.  
  82.  
  83.  
  84.  
  85.  
  86.  
  87.  
  88. --Mario
  89. HPM = memory.readword(0x02004866)
  90. HPmaxM = memory.readword(0x0200486A)
  91. BPM = memory.readword(0x0200486c)
  92. BPmaxM = memory.readword(0x02004870)
  93. PowM = memory.readword(0x02004874)
  94. DefM = memory.readword(0x0200487c)
  95. SpeedM = memory.readword(0x02004878)
  96. HigeM = memory.readword(0x02004880)
  97. levelM = memory.readbyte(0x02004888)
  98. ExpM = memory.readword(0x0200485c)
  99.  
  100.  
  101. -- This calculates how much experience you have to get for the next level.
  102. -- The NextM/NextL values seem to be hardcoded into the game.
  103. NextM = 0
  104. if levelM == 1 then NextM = 7
  105.  
  106. elseif levelM == 2 then NextM = 32
  107. elseif levelM == 3 then NextM = 68
  108. elseif levelM == 4 then NextM = 108
  109. elseif levelM == 5 then NextM = 218
  110. elseif levelM == 6 then NextM = 336
  111. elseif levelM == 7 then NextM = 470
  112. elseif levelM == 8 then NextM = 694
  113. elseif levelM == 9 then NextM = 962
  114. elseif levelM == 10 then NextM = 1254
  115. elseif levelM == 11 then NextM = 1578
  116. elseif levelM == 12 then NextM = 1924
  117. elseif levelM == 13 then NextM = 2306
  118. elseif levelM == 14 then NextM = 2756
  119. elseif levelM == 15 then NextM = 3256
  120. elseif levelM == 16 then NextM = 3830
  121. elseif levelM == 17 then NextM = 4480
  122. elseif levelM == 18 then NextM = 5195
  123. elseif levelM == 19 then NextM = 5975
  124. elseif levelM == 20 then NextM = 6845
  125. else NextM = 0 end
  126.  
  127. NextexpM = NextM - ExpM
  128.  
  129. --Luigi
  130. HPL = memory.readword(0x020048a2)
  131. HPmaxL = memory.readword(0x020048a6)
  132. BPL = memory.readword(0x020048a8)
  133. BPmaxL = memory.readword(0x020048ac)
  134. PowL = memory.readword(0x020048b0)
  135. DefL = memory.readword(0x020048b8)
  136. SpeedL = memory.readword(0x020048b4)
  137. HigeL = memory.readword(0x020048bc)
  138. levelL = memory.readbyte(0x020048c4)
  139. ExpL = memory.readword(0x02004898)
  140.  
  141. -- 'Next' calculator
  142. NextL = 0
  143. if levelL == 1 then NextL = 10
  144. elseif levelL == 2 then NextL = 37
  145. elseif levelL == 3 then NextL = 77
  146. elseif levelL == 4 then NextL = 123
  147. elseif levelL == 5 then NextL = 233
  148. elseif levelL == 6 then NextL = 353
  149. elseif levelL == 7 then NextL = 493
  150. elseif levelL == 8 then NextL = 699
  151. elseif levelL == 9 then NextL = 969
  152. elseif levelL == 10 then NextL = 1272
  153. elseif levelL == 11 then NextL = 1552
  154. elseif levelL == 12 then NextL = 1898
  155. elseif levelL == 13 then NextL = 2280
  156. elseif levelL == 14 then NextL = 2730
  157. elseif levelL == 15 then NextL = 3239
  158. elseif levelL == 16 then NextL = 3813
  159. elseif levelL == 17 then NextL = 4463
  160. elseif levelL == 18 then NextL = 5178
  161. elseif levelL == 19 then NextL = 5958
  162. elseif levelL == 20 then NextL = 6858
  163. elseif levelL == 20 then NextL = 6845
  164. else NextL = 0 end
  165.  
  166. NextexpL = NextL - ExpL
  167.  
  168.  
  169. -- display
  170.  if mushrooms == -1 then mushrooms = 0 end
  171.  if supermushrooms == -1 then supermushrooms = 0 end
  172.  if ultramushrooms == -1 then ultramushrooms = 0 end
  173.  if maxmushrooms == -1 then maxmushrooms = 0 end
  174.  if nuts == -1 then nuts = 0 end
  175.  if supernuts == -1 then supernuts = 0 end
  176.  if ultranuts == -1 then ultranuts = 0 end
  177.  if maxnuts == -1 then maxnuts = 0 end
  178.  if syrups == -1 then syrups = 0 end
  179.  if supersyrups == -1 then supersyrups = 0 end
  180.  if ultrasyrups == -1 then ultrasyrups = 0 end
  181.  if maxsyrups == -1 then maxsyrups = 0 end
  182.  if ONEups == -1 then ONEups = 0 end
  183.  if ONEupDXs == -1 then ONEupDXs = 0 end
  184.  if redpeppers == -1 then redpeppers = 0 end
  185.  if greenpeppers == -1 then greenpeppers = 0 end
  186.  if herbs == -1 then herbs = 0 end
  187.  if goldmushrooms == -1 then goldmushrooms = 0 end
  188.  if ahastraights == -1 then ahastraights = 0 end
  189.  if ufustraights == -1 then ufustraights = 0 end
  190.  if gerastraights == -1 then gerastraights = 0 end
  191.  if dehestraights == -1 then dehestraights = 0 end
  192.  if ufumanjaros == -1 then ufumanjaros = 0 end
  193.  if gerapuccinos == -1 then gerapuccinos = 0 end
  194.  if dehepressos == -1 then dehepressos = 0 end
  195.  if ahabeans == -1 then ahabeans = 0 end
  196.  if ufubeans == -1 then ufubeans = 0 end
  197.  if gerabeans == -1 then gerabeans = 0 end
  198.  if dehebeans == -1 then dehebeans = 0 end
  199.  
  200.  
  201. gui.text(18+x,1+y, mushrooms)
  202. gui.text(28+x,1+y, supermushrooms)
  203. gui.text(38+x,1+y, ultramushrooms)
  204. gui.text(48+x,1+y, maxmushrooms)
  205.  
  206. --gui.text(133+x,1+y, "(" ..mushrooms*0.078 + supermushrooms*0.098 + ultramushrooms*0.117 + maxmushrooms*0.199 .. ")" , "yellow")
  207.  
  208. gui.text(18+x,7+y, nuts)
  209. gui.text(28+x,7+y, supernuts)
  210. gui.text(38+x,7+y, ultranuts)
  211. gui.text(48+x,7+y, maxnuts)
  212.  
  213. gui.text(18+x,13+y, syrups)
  214. gui.text(28+x,13+y, supersyrups)
  215. gui.text(38+x,13+y, ultrasyrups)
  216. gui.text(48+x,13+y, maxsyrups)
  217.  
  218. --gui.text(57+x,1+y, "=" ..mushrooms*20+supermushrooms*50+ultramushrooms*110+maxmushrooms*280 ,"#81F7F3")
  219. --gui.text(78+x,1+y, mushrooms*24+supermushrooms*60+ultramushrooms*100+maxmushrooms*180 ,"#ACFA58")
  220.  
  221. --gui.text(57+x,7+y, "=" ..nuts*50+supernuts*120+ultranuts*260+maxnuts*340 , "#81f7f3")
  222. --gui.text(78+x,7+y, nuts*50+supernuts*90+ultranuts*140+maxnuts*220 , "#acfa58")
  223.  
  224. --gui.text(57+x,13+y, "=" ..syrups*24+supersyrups*50+ultrasyrups*80+maxsyrups*280 , "#81f7f3")
  225. --gui.text(78+x,13+y, syrups*24+supersyrups*50+ultrasyrups*80+maxsyrups*150 , "#acfa58")
  226.  
  227.  
  228. --gui.text(22+x,19+y, "=" ..ONEups*70+ONEupDXs*420+herbs*30+goldmushrooms*105+redpeppers*30+greenpeppers*30+ahastraights*100+ufustraights*100+gerastraights*100+dehestraights*100+ufumanjaros*100+gerapuccinos*100+dehepressos*100 , "#81f7f3")
  229. --gui.text(43+x,19+y, ONEups*80+ONEupDXs*240+herbs*30+goldmushrooms*60+redpeppers*50+greenpeppers*50+ahastraights*100+ufustraights*100+gerastraights*100+dehestraights*100+ufumanjaros*100+gerapuccinos*100+dehepressos*100 , "#acfa58")
  230.  
  231. gui.text(59+x,13+y, "$" ..memory.readword(0x020048e0), "yellow")
  232.  
  233. gui.text(82+x,1+y, "(M)", "#F78181")
  234. gui.text(116+x,1+y, "(L)", "#ACFA58")
  235. gui.text(94+x,1+y, "Lv" .. levelM)
  236. gui.text(128+x,1+y, "Lv" .. levelL)
  237. gui.text(82+x,7+y, "BP ", "#FFCC66")
  238. gui.text(93+x,7+y, BPM .. "/" .. BPmaxM .. "  " .. BPL .. "/" .. BPmaxL)
  239. gui.text(82+x,13+y, "Pow  " , "#EAADEA")
  240. gui.text(94+x,19+y, "hige " , "#A9F5D0")
  241. --gui.text(86+x,25+y, "NEXT ", "#A9D0F5")
  242. gui.text(102+x,13+y, PowM .. "   " .. PowL)
  243. gui.text(116+x,19+y, HigeM .. "   " .. HigeL)
  244. --gui.text(107+x,25+y, NextexpM .. "   " .. NextexpL)
  245.  
  246. --Bros Attacks counters
  247. SplashCounter = 20 - memory.readbyte(0x02004684)
  248. if SplashCounter < 0 then SplashCounter = 0 end
  249. BounceCounter = 8 - memory.readbyte(0x0200468c)
  250. if BounceCounter < 0 then BounceCounter = 0 end
  251. ChopperCounter = 32 - memory.readbyte(0x02004686)
  252. if ChopperCounter < 0 then ChopperCounter = 0 end
  253. KnockCounter = 43 - memory.readbyte(0x0200468e)
  254. if ChopperCounter < 0 then KnockCounter = 0 end
  255.  
  256.  
  257. gui.text(9+x,19+y, "S="..  SplashCounter)
  258. gui.text(30+x,19+y, "B=".. BounceCounter)
  259. gui.text(47+x,19+y, "C="..  ChopperCounter)
  260. gui.text(68+x,19+y, "K="..  KnockCounter)
  261.  
  262. -- RNG
  263. gui.text(61+x,1+y, memory.readbytesigned(0x02001e60))
  264. gui.text(61+x,7+y, memory.readbytesigned(0x02001e64))
  265.  
  266.  
  267. --Movie active?
  268. if movie.active()~=true then gui.drawbox(29,29,140,39, "red") end
  269. gui.opacity(0.9)
  270. if movie.active()~=true then gui.text(35,31, "!! MOVIE NOT RECORDING !!") end
  271.  
  272.  
  273. ---- POS
  274. gui.text(150+x, 1+y, memory.readdwordsigned(0x02006c14), "#F78181")
  275. gui.text(150+x, 7+y, memory.readdwordsigned(0x02006c18), "#F78181")
  276. gui.text(150+x, 13+y, memory.readdwordsigned(0x02006fb0), "#ACFA58")
  277. gui.text(150+x, 19+y, memory.readdwordsigned(0x02006fb4), "#ACFA58")
  278.  
  279. ---- MISC
  280. --gui.text(10,80, "Birdo hp " ..memory.readword(0x02008fe2), "yellow")
  281. --gui.text(10,89, "Bowletta hp " ..memory.readword(0x0200a912)-5000, "yellow")
  282.  
  283.  
  284.  
  285.  
  286. vba.frameadvance()
  287. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement