Advertisement
Arnethegreat

Game Modes Lua for Yoshi's Island WIP

Feb 5th, 2012
902
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 38.38 KB | None | 0 0
  1. -- Version 0.33b
  2. -- OPTIONS -- OPTIONS -- OPTIONS -- Change to true or false
  3.  
  4. Level_Blitz = false
  5. NoLeftMode = false
  6. DisableButton = "none"
  7. DrunkMode = false
  8. HardMode = false
  9. ForceRetry = false
  10. InfiniteLives = false
  11. DeathTimer = true  -- When the star meter hits 0, you die. Combine with Hard Mode for Insane Mode (1-hit death)
  12. AlwaysExtendedFlutter = false
  13. NoFlutter = false
  14. NoTongue = false
  15. Velcro = false
  16. AlwaysFilledMouth = false -- Enter 2 for bubbles and 3 for melons. Enter false to disable
  17. FullEggsStart = true
  18. NumberOfEggs = 6 -- For FullEggsStart, how many to start with - choose between 1-6
  19. EggType = 37-- What eggs to start with (34 = flashing egg - 35 = red - 36 = yellow - 37 = green - 39 = key - 40 = chicken - 43 = big egg
  20. FastModeX = false
  21. FastModeY = false
  22. SpeedBoostX = 5 -- For fast mode, enter (-9) to 9 (higher is faster)
  23. SpeedBoostY = 8
  24. PoisonCoins = -10 -- Put 0 to disable. 10 = 1 star per coin. Negative values give stars.
  25. PoisonFlowers = -50
  26. GroundIsLava = 80 -- Put 0 to disable. 20 = about 1 star per second
  27. TerminalMode = 0 -- Put 0 to disable. Same rate as above
  28. PoisonAir = 0 -- Just as GroundIsLava but in air instead.
  29. PackMuleMode = false -- Only works when combined with Fast Mode
  30. StarMeterSpeedMode = false -- poop, don't use yet. (it's poop)
  31.  
  32. -- Level Blitz Options -- Level Blitz Options --
  33.  
  34. AutoScrollers = false
  35. ExtraStages = false
  36. ExcludeStages = {68, 72, 54}  -- seperate by a comma, write stages like 54 as 5-4
  37. CustomLevelOrder = {}
  38. NormalFortressOrder = true
  39. NormalCastleOrder = true
  40. RandomSeed = 18467
  41. SameStage = false
  42. Fortresses = true
  43. Castles = true
  44. World1 = true
  45. World2 = true
  46. World3 = true
  47. World4 = true
  48. World5 = true
  49. World6 = true
  50.  
  51. -- Level Goals Options -- Level Goals Options --
  52.  
  53. CoinGoals = false       -- set true if you wan't to use it
  54. MinimumCoins = true     -- set true if you want a minimum goal
  55. MaximumCoins = false    -- set true if you wanta a maximum goal
  56. MinCoinGoal = 200       -- set what minimum goal must be met
  57. MaxCoinGoal = 0         -- set what the maxiumum goal can be - death when getting more than max
  58. DisplayCoin = true      -- whether to display on screen or not
  59.  
  60. StarGoals = false
  61. MinimumStars = false
  62. MaximumStars = true
  63. MinStarGoal = 0
  64. MaxStarGoal = 25
  65. DisplayStar = true
  66.  
  67. FlowerGoals = false
  68. MinimumFlowers = true
  69. MaximumFlowers = true
  70. MinFlowerGoal = 3
  71. MaxFlowerGoal = 3
  72. DisplayFlower = true
  73.  
  74. RedCoinGoals = false
  75. MinimumRedCoins = true
  76. MaximumRedCoins = false
  77. MinRedCoinGoal = 4
  78. MaxRedCoinGoal = 0
  79. DisplayRed = true
  80.  
  81. JumpGoals = false
  82. MinimumJumps = false
  83. MaximumJumps = true
  84. MinJumpGoal = 0
  85. MaxJumpGoal = 100
  86. DisplayJump = true
  87.  
  88. Egg_Goals = false
  89. MinimumEggs = true
  90. MaximumEggs = false
  91. MinEggGoal = 25
  92. MaxEggGoal = 100
  93. DisplayEggs = true
  94.  
  95. Fuzzy_Goals = false
  96. MinimumFuzzies = false
  97. MaximumFuzzies = true
  98. MinFuzzyGoal = 5
  99. MaxFuzzyGoal = 5
  100. DisplayFuzzy = true
  101.  
  102. Lives_Goals = false
  103. MinimumLives = true
  104. MaximumLives = true
  105. MinLivesGoal = 5
  106. MaxLivesGoal = 5
  107. DisplayLives = true
  108.  
  109. gui.opacity(0.8) -- set opacity for text displayed
  110.  
  111. -- OPTIONS End -- OPTIONS End -- OPTIONS End --
  112.  
  113. -- !Instructions! Instructions! Instructions! Instructions!
  114. -- 1. You must use a lua compatible Snes9x emulator. Recommended is -> http://code.google.com/p/snes9x-rr/downloads/detail?name=snes9x-1.51-rerecording-svn147.zip&can=2&q=
  115. -- 2. Recommended ROM is (U) (1.0) (!) but others should work but they are untested
  116. -- 3. Change options above and replace with true or false, RandomSeed is a number though, if it's a word, it's just random
  117. -- 4. In Snes9x, load ROM then go File -> Lua Scripting -> New Lua Script Window... -> Load file -> Press Run
  118. -- 5. You know you have loaded it right when the Lua Script window outputs what modes are on and what are false
  119. -- 6. If you have changed the options, you have to restart the script for it to take effect
  120. -- Newest version is always found at http://pastebin.com/qCGDbZZZ
  121. ------------------------------------------------
  122. ------------------------------------------------
  123. ------------------------------------------------
  124. ----------------Script starts here--------------
  125. ------------------------------------------------
  126. ------------------------------------------------
  127. ------------------------------------------------
  128. ------------------------------------------------
  129. ------------------------------------------------
  130. function table.contains(table, element)
  131.   for i, value in pairs(table) do
  132.     if value == element then
  133.       valpos = i
  134.       return true
  135.     end
  136.   end
  137.   return false
  138. end
  139.  
  140. function deepcopy(t)
  141.     if type(t) ~= 'table' then return t end
  142.     local mt = getmetatable(t)
  143.     local res = {}
  144.     for k,v in pairs(t) do
  145.         if type(v) == 'table' then
  146.             v = deepcopy(v)
  147.         end
  148.         res[k] = v
  149.     end
  150.     setmetatable(res,mt)
  151.     return res
  152. end
  153.  
  154. function removetable(tab,tab2)
  155.     table.sort(tab)
  156.     table.sort(tab2)
  157.     rem = 0
  158.     tabcopy = deepcopy(tab)
  159.         for cy, value in ipairs(tab) do
  160.               for cx, value2 in ipairs (tab2) do
  161.                 if value == value2 then
  162.                     table.remove(tabcopy,cy - rem)
  163.                     rem = rem + 1
  164.                 end
  165.               end
  166.         end
  167.     return tabcopy
  168. end
  169.  
  170. function convertstages(tablelist)
  171.     for i, stg in pairs(tablelist) do
  172.         worldnumber = math.floor(stg/10)
  173.         levelnumber = stg - worldnumber*10
  174.         realstagevalue = (worldnumber - 1)*12 + levelnumber - 1
  175.         tablelist[i] = realstagevalue
  176.     end
  177. end
  178. ------------------------------------------------
  179. ------------------------------------------------
  180. ------------------------------------------------
  181. print("Version 0.33b")
  182. NumberOfEggs = NumberOfEggs*2
  183. gpsn_value = 0
  184. apsn_value = 0
  185. psn_value = 0
  186. eggcount = 0
  187. keycount = 0
  188. mouth_var = 0
  189. packmulemodifier = 1
  190. laststage = 0
  191. lastworld = 0
  192. scrollerslist = {4, 53, 64} -- This can be changed to include or exclude other stages depending on how you define an autoscroller
  193. extralist = {8, 20, 32, 44, 56, 68}
  194. castlelist = {7, 19, 31, 43, 55}
  195. fortresslist = {3, 15, 27, 39, 51, 63}
  196. world1list = {0, 1, 2, 3, 4, 5, 6, 7, 8 }
  197. world2list = {12, 13, 14, 15, 16, 17, 18, 19, 20}
  198. world3list = {24, 25, 26, 27, 28 ,29, 30, 31, 32}
  199. world4list = {36, 37, 38, 39, 40, 41, 42, 43, 44}
  200. world5list = {48, 49, 50, 51, 52, 53, 54, 55, 56}
  201. world6list = {60, 61, 62, 63, 64, 65, 66, 68}
  202. stageslist =
  203. {0, 1, 2, 3, 4, 5, 6, 7, 8,
  204. 12, 13, 14, 15, 16, 17, 18, 19, 20,
  205. 24, 25, 26, 27, 28 ,29, 30, 31, 32,
  206. 36, 37, 38, 39, 40, 41, 42, 43, 44,
  207. 48, 49, 50, 51, 52, 53, 54, 55, 56,
  208. 60, 61, 62, 63, 64, 65, 66, 68}
  209. -- Remove stages according to options
  210. if AutoScrollers == false then
  211.     stageslist = removetable(stageslist, scrollerslist)
  212. end
  213.  
  214. if ExtraStages == false then
  215.     stageslist = removetable(stageslist, extralist)
  216. end
  217.  
  218. if World1 == false then
  219.     stageslist = removetable(stageslist, world1list)
  220. end
  221.  
  222. if World2 == false then
  223.     stageslist = removetable(stageslist, world2list)
  224. end
  225.  
  226. if World3 == false then
  227.     stageslist = removetable(stageslist, world3list)
  228. end
  229.  
  230. if World4 == false then
  231.     stageslist = removetable(stageslist, world4list)
  232. end
  233.  
  234. if World5 == false then
  235.     stageslist = removetable(stageslist, world5list)
  236. end
  237.  
  238. if World6 == false then
  239.     stageslist = removetable(stageslist, world6list)
  240. end
  241.  
  242. if Fortresses == false or NormalFortressOrder == true then
  243.     stageslist = removetable(stageslist, fortresslist)
  244. end
  245.  
  246. if Castles == false or NormalCastleOrder == true then
  247.     stageslist = removetable(stageslist, castlelist)
  248. end
  249.  
  250. convertstages(ExcludeStages)
  251. stageslist = removetable(stageslist, ExcludeStages)
  252. castlelist = removetable(castlelist, ExcludeStages)
  253. fortresslist = removetable(fortresslist, ExcludeStages)
  254. --
  255. if RandomSeed ~= nil then
  256.     math.randomseed(RandomSeed)
  257. end
  258. --
  259. ------------------------------------------------
  260. --------------------GAMEMODES-------------------
  261. ------------------------------------------------
  262. ------------------------------------------------
  263. if Level_Blitz == true then
  264.     gen_levelblitz = {}
  265.     numberofstages = #stageslist
  266.     if Castles == true then
  267.         numberofstages = numberofstages + #castlelist
  268.     end
  269.     if Fortresses == true then
  270.         numberofstages = numberofstages + #fortresslist
  271.     end
  272.     instage = 0
  273.     xlbgen = 1
  274.  
  275.     if SameStage == false then
  276.         function SameStage(remstagelist)
  277.             table.remove(remstagelist,gen_stgnr)
  278.         end
  279.     else
  280.         function SameStage()
  281.         end
  282.     end
  283.     if #CustomLevelOrder == 0 then
  284.         while xlbgen <= numberofstages do
  285.             if xlbgen%8 == 0 and #castlelist > 0 and NormalCastleOrder == true then
  286.                 gen_stgnr = math.random(#castlelist)
  287.                 gen_stage = castlelist[gen_stgnr]
  288.                 table.insert(gen_levelblitz,gen_stage)
  289.                 SameStage(castlelist)
  290.             elseif xlbgen%4 == 0 and xlbgen%8 ~= 0 and #fortresslist > 0 and NormalFortressOrder == true then
  291.                 gen_stgnr = math.random(#fortresslist)
  292.                 gen_stage = fortresslist[gen_stgnr]
  293.                 table.insert(gen_levelblitz,gen_stage)
  294.                 SameStage(fortresslist)
  295.             elseif #stageslist > 0 then
  296.                 gen_stgnr = math.random(#stageslist)
  297.                 gen_stage = stageslist[gen_stgnr]
  298.                 table.insert(gen_levelblitz,gen_stage)
  299.                 SameStage(stageslist)
  300.             end
  301.             xlbgen = xlbgen + 1
  302.         end
  303.     else
  304.         convertstages(CustomLevelOrder)
  305.         gen_levelblitz = CustomLevelOrder
  306.         numberofstages = #gen_levelblitz
  307.     end
  308.  
  309.     function LevelBlitz()
  310.         stagenumber = memory.readbyte(0x7E1112)   --//or memory.readbyte(0x7E112E)
  311.         worldnumber= memory.readbyte(0x7E0218)
  312.         entering_stage = memory.readbyte(0x7E111D)
  313.         overworld = memory.readbyte(0x7E0009)
  314.         titlescreen = memory.readbyte(0x7E011C)
  315.         if stagenumber < 8 and instage == 0 and entering_stage == 1 and titlescreen == 12 then
  316.             laststage = stagenumber
  317.             lastworld = worldnumber
  318.             corresponding_stage = (worldnumber/2)*8 + stagenumber+1
  319.             if corresponding_stage <= numberofstages then
  320.                 memory.writebyte(0x7E021A,gen_levelblitz[corresponding_stage])
  321.             end
  322.             instage = 1
  323.         elseif overworld == 126 then
  324.             memory.writebyte(0x7E021A, laststage+lastworld*6)
  325.             memory.writebyte(0x7E0218, lastworld) -- This is not needed? Kept just in case
  326.         elseif entering_stage ~= 1 then
  327.             instage = 0
  328.         end
  329.     end
  330.     print("Blitz Mode is ON")
  331. else
  332.     function LevelBlitz()
  333.     end
  334.     print("Blitz Mode is OFF")
  335. end
  336. -----------------------------------------------
  337. ------------------------------------------------
  338. if NoLeftMode == true then
  339.     function noleft()
  340.         speed = memory.readwordsigned(0x7000B4)
  341.         if speed < 0 and memory.readbyte(0x7000AC) == 0 then
  342.             memory.writeword(0x7000B4,0)
  343.         end
  344.     end
  345.     print("NoLeftMode is ON")
  346. else
  347.     function noleft()
  348.     end
  349.     print("NoLeftMode is OFF")
  350. end
  351. -------------------------------------------------
  352. -------------------------------------------------
  353. if DrunkMode == true then
  354.     function drunk()
  355.         if memory.readbyte(0x7E0118) == 16 or memory.readbyte(0x7E0118) == 57 then
  356.             memory.writeword(0x701FE8, 0)
  357.         else
  358.             memory.writeword(0x701FE8, 10)
  359.         end
  360.     end
  361.     print("Drunk Mode is ON")
  362. else
  363.     function drunk()
  364.     end
  365.     print("Drunk Mode is OFF")
  366. end
  367. -------------------------------------------------
  368. -------------------------------------------------
  369. if HardMode == true then
  370.     timerreset = 1
  371.     function hardmode()
  372.         gamemode = memory.readbyte(0x7E0118)
  373.         hit = memory.readbyte(0x701960)
  374.         if hit == 85 and timerreset == 0 and gamemode == 15 then
  375.             memory.writeword(0x7E03B6, 1)
  376.             timerreset = 1
  377.         elseif hit ~= 85 and timerreset == 1 then
  378.             timerreset = 0
  379.             memory.writeword(0x7E03B6, 100)
  380.         end
  381.     end
  382.     print("Hard Mode is ON")
  383. else
  384.     function hardmode()
  385.     end
  386.     print("Hard Mode is OFF")
  387. end
  388. -------------------------------------------------
  389. -------------------------------------------------
  390. if ForceRetry == true then
  391.     function forceretry()
  392.         if memory.readbyte(0x7E0118) == 61 or memory.readbyte(0x7E0118) == 53 then
  393.             memory.writebyte(0x704094, 0)
  394.         end
  395.     end
  396.     print("Force Retry Mode is ON")
  397. else
  398.     function forceretry()
  399.     end
  400.     print("Force Retry Mode is OFF")
  401. end
  402. -------------------------------------------------
  403. -------------------------------------------------
  404. if InfiniteLives == true then
  405.     function infinitelives()
  406.         memory.writebyte(0x7E0379, 10)
  407.     end
  408.     print("Infinite Lives is ON")
  409. else
  410.     function infinitelives()
  411.     end
  412.     print("Infinite Lives is OFF")
  413. end
  414. -------------------------------------------------
  415. -------------------------------------------------
  416. -------------------------------------------------
  417. -------------------------------------------------
  418. function firedeath()
  419.     memory.writebyte(0x7000AC, 40)
  420.     memory.writebyte(0x7001B0, 40)
  421.     memory.writebyte(0x7001D2, 34)
  422.     memory.writebyte(0x002140, 07)
  423.     yoshiisdead = false
  424.     die = 0
  425. end
  426. if DeathTimer == true then
  427.     yoshiisdead = false
  428.     function deathtimer()
  429.         startimer = memory.readword(0x7E03B6)
  430.         gamemode = memory.readbyte(0x7E0118)
  431.         if gamemode ~= 15 then
  432.             die = 1
  433.         end
  434.         if startimer <= 1  and die == 1 and gamemode == 15 then
  435.             yoshiisdead = true
  436.         end
  437.         if memory.readbyte(0x7001AE) == 0 and memory.readbyte(0x7000AC) == 0 and yoshiisdead == true then
  438.             firedeath()
  439.         end
  440.     end
  441.     print("Death Timer Mode is ON")
  442. else
  443.     function deathtimer()
  444.     end
  445.     print("Death Timer Mode is OFF")
  446. end
  447. -------------------------------------------------
  448. -------------------------------------------------
  449. if AlwaysExtendedFlutter == true then
  450.     function extendedflutter()
  451.         mario = memory.readbyte(0x7E0205)
  452.         if mario == 1 then
  453.             memory.writebyte(0x7000D3, 128)
  454.         end
  455.     end
  456.     print("Always Extended Flutter is ON")
  457. else
  458.     function extendedflutter()
  459.     end
  460.     print("Always Extended Flutter is OFF")
  461. end
  462. -------------------------------------------------
  463. -------------------------------------------------
  464. if NoTongue == true then
  465.     function notongue()
  466.         memory.writebyte(0x700162, 126)
  467.     end
  468.     print("No Tongue Mode is ON")
  469. else
  470.     function notongue()
  471.     end
  472.     print("No Tongue Mode is OFF")
  473. end
  474. -------------------------------------------------
  475. -------------------------------------------------
  476. if NoFlutter == true then
  477.     function noflutter()
  478.         memory.writebyte(0x7000D2, 0)
  479.     end
  480.     print("No Flutter Mode is ON")
  481. else
  482.     function noflutter()
  483.     end
  484.     print("No Flutter Mode is OFF")
  485. end
  486. -------------------------------------------------
  487. ------------------------------------------------- -- Boss cutscenes are very slow, fix if people think it's a problem.
  488. if Velcro == true then
  489.     function velcromode()
  490.         if memory.readbyte(0x7000C0) == 0 and memory.readbyte(0x7E0118) == 15 and math.abs(memory.readwordsigned(0x7000B4)) > 20 then
  491.             memory.writeword(0x7000B4,0)
  492.         end
  493.     end
  494.     print("Velcro Mode is ON")
  495. else
  496.     function velcromode()
  497.     end
  498.     print("Velcro Mode is OFF")
  499. end
  500. -------------------------------------------------
  501. -------------------------------------------------
  502. if AlwaysFilledMouth == false then
  503.     function mouthmode()
  504.     end
  505.     print("Always Filled Mouth is OFF")
  506. else
  507.     if AlwaysFilledMouth == melon or AlwaysFilledMouth == melons or AlwaysFilledMouth == seeds or AlwaysFilledMouth == melonseeds or AlwaysFilledMouth == melonseed then
  508.         mouth_var = 3
  509.     end
  510.     if AlwaysFilledMouth == bubble or AlwaysFilledMouth == bubbles then
  511.         mouth_var = 2
  512.     end
  513.     function mouthmode()
  514.     memory.writebyte(0x700162, 89)
  515.     memory.writebyte(0x70016A, AlwaysFilledMouth)
  516.     memory.writebyte(0x700170, 30)
  517.     end
  518.     print("Always Filled Mouth is ON")
  519. end
  520. -------------------------------------------------
  521. -------------------------------------------------
  522. if FullEggsStart == true then
  523.     function eggstransitions()
  524.         gamemode = memory.readbyte(0x7E0118)
  525.         if gamemode == 12 then
  526.             eggcount = memory.readbyte(0x7E5D98)
  527.             for i = 0, eggcount, 2 do
  528.                 memory.writebyte(0x7E5D9A + i, memory.readbyte(0x7E5D9A + i))
  529.             end
  530.             for i = eggcount, NumberOfEggs, 2 do
  531.                 memory.writebyte(0x7E5D9A+i, EggType)
  532.             end
  533.             if eggcount > NumberOfEggs then
  534.                 memory.writebyte(0x7E5D98, eggcount)
  535.             else
  536.                 memory.writebyte(0x7E5D98, NumberOfEggs)
  537.             end
  538.         end
  539.     end
  540.     print("Always Start With Full Eggs  is ON -", NumberOfEggs/2, "eggs")
  541. else
  542.     function eggstransitions()
  543.     end
  544.     print("Always Start With Full Eggs is OFF")
  545. end
  546. -------------------------------------------------
  547. -------------------------------------------------
  548. xposoffset = 0
  549. if FastModeX == true then
  550.     speedmodifierx = 1000 - SpeedBoostX*100
  551.     function fastmodex()
  552.         if memory.readbyte(0x7E0118) == 15 and memory.readbyte(0x7E0387) == 0 then
  553.             xspeed = memory.readwordsigned(0x7000B4)
  554.             xposition = memory.readwordsigned(0x70008c)
  555.             xposoffset = xspeed/speedmodifierx
  556.             memory.writeword(0x70008c, xposition + xposoffset)
  557.         end
  558.     end
  559.     print("Fast Mode is ON - Speed:",SpeedBoostX)
  560. else
  561.     function fastmodex()
  562.     end
  563.     print("Fast Mode is OFF")
  564. end
  565. -------------------------------------------------
  566. -------------------------------------------------
  567. if FastModeY == true then
  568.     speedmodifiery = 1000 - SpeedBoostY*100
  569.     function fastmodey()
  570.         if memory.readbyte(0x7E0118) == 15 and memory.readbyte(0x7E0387) == 0 then
  571.             yspeed = memory.readwordsigned(0x7000AA)
  572.             yposition = memory.readwordsigned(0x700090)
  573.             memory.writeword(0x700090, yposition + yspeed/speedmodifiery)
  574.         end
  575.     end
  576.     print("Fast Mode is ON - Speed:",SpeedBoostY)
  577. else
  578.     function fastmodey()
  579.     end
  580.     print("Fast Mode is OFF")
  581. end
  582. -------------------------------------------------
  583. -------------------------------------------------
  584. if PoisonCoins ~= 0 then
  585.     lastframecoins = memory.readbyte(0x7E037B)
  586.     function poisoncoins()
  587.         starcounter = memory.readword(0x7E03B6)
  588.         if memory.readbyte(0x7E037B) > lastframecoins  then
  589.             if starcounter > PoisonCoins then
  590.                 memory.writeword(0x7E03B6,  starcounter - PoisonCoins)
  591.             else
  592.                 memory.writeword(0x7E03B6,  0)
  593.             end
  594.         end
  595.         lastframecoins = memory.readbyte(0x7E037B)
  596.     end
  597.     print("Poison Coins Mode is ON")
  598. else
  599.     function poisoncoins()
  600.     end
  601.     print("Poison Coins Mode is OFF")
  602. end
  603. -------------------------------------------------
  604. -------------------------------------------------
  605. if PoisonFlowers ~= 0 then
  606.     lastframeflowers = memory.readbyte(0x7E03B8)
  607.     function poisonflowers()
  608.         starcounter = memory.readword(0x7E03B6)
  609.         if memory.readbyte(0x7E03B8) > lastframeflowers  then
  610.             if starcounter > PoisonFlowers then
  611.                 memory.writeword(0x7E03B6,  starcounter - PoisonFlowers)
  612.             else
  613.                 memory.writeword(0x7E03B6,  0)
  614.             end
  615.         end
  616.         lastframeflowers = memory.readbyte(0x7E03B8)
  617.     end
  618.     print("Poison Flowers Mode is ON")
  619. else
  620.     function poisonflowers()
  621.     end
  622.     print("Poison Flowers Mode is OFF")
  623. end
  624. -------------------------------------------------
  625. -------------------------------------------------
  626. if GroundIsLava ~= 0 then
  627.     GroundIsLava = GroundIsLava + 9
  628.     function groundislava()
  629.         starcounter = memory.readword(0x7E03B6)
  630.         if memory.readbyte(0x7000C0) == 0 and memory.readbyte(0x7001AE) == 0 and memory.readbyte(0x7000AC) == 0 then
  631.             if starcounter > 0 then
  632.                 if gpsn_value >= 1 or gpsn_value <= -1 then
  633.                     memory.writeword(0x7E03B6,  starcounter - gpsn_value)
  634.                     gpsn_value = 0
  635.                 end
  636.             gpsn_value = gpsn_value + 0.01*GroundIsLava
  637.             else
  638.                 memory.writeword(0x7E03B6,  0)
  639.             end
  640.         end
  641.     end
  642.     print("Ground is Lava Mode is ON")
  643. else
  644.     function groundislava()
  645.     end
  646.     print("Ground is Lava is OFF")
  647. end
  648. -------------------------------------------------
  649. -------------------------------------------------
  650. if PoisonAir ~= 0 then
  651.     PoisonAir = PoisonAir + 9
  652.     function poisonair()
  653.         starcounter = memory.readword(0x7E03B6)
  654.         if memory.readbyte(0x7000C0) ~= 0 and memory.readbyte(0x7001AE) == 0 and memory.readbyte(0x7000AC) == 0 then
  655.             if starcounter > 0 then
  656.                 if apsn_value >= 1 or apsn_value <= -1 then
  657.                     memory.writeword(0x7E03B6,  starcounter - apsn_value)
  658.                     apsn_value = 0
  659.                 end
  660.             apsn_value = apsn_value + 0.01*PoisonAir
  661.             else
  662.                 memory.writeword(0x7E03B6,  0)
  663.             end
  664.         end
  665.     end
  666.     print("Poison Air Mode is ON")
  667. else
  668.     function poisonair()
  669.     end
  670.     print("Poison Air is OFF")
  671. end
  672. -------------------------------------------------
  673. -------------------------------------------------
  674. if TerminalMode ~= 0 then
  675.     TerminalMode = TerminalMode + 9
  676.     function terminalmode()
  677.         starcounter = memory.readword(0x7E03B6)
  678.         if memory.readbyte(0x7001AE) == 0 and memory.readbyte(0x7000AC) == 0 then
  679.             if starcounter > 0 then
  680.                 if psn_value >= 1 or psn_value <= -1 then
  681.                     memory.writeword(0x7E03B6,  starcounter - psn_value)
  682.                     psn_value = 0
  683.                 end
  684.                 psn_value = psn_value + 0.01*TerminalMode
  685.             else
  686.                 memory.writeword(0x7E03B6,  0)
  687.             end
  688.         end
  689.     end
  690.     print("Terminal Mode is ON")
  691. else
  692.     function terminalmode()
  693.     end
  694.     print("Terminal Mode is OFF")
  695. end
  696. -------------------------------------------------
  697. -------------------------------------------------
  698. if PackMuleMode == true then
  699.     function packmule()
  700.         packmulemodifier = (-1)*memory.readbyte(0x701DF6)/2
  701.     end
  702.     print("Pack Mule Mode is ON")
  703. else
  704.     packmulemodifier = 0
  705.     function packmule()
  706.     end
  707.     print("Pack Mule Mode is OFF")
  708. end
  709. -------------------------------------------------
  710. -------------------------------------------------
  711. if StarMeterSpeedMode == true then
  712.     starmetermodifier = 1
  713.     function starmeterspeed()
  714.         starmetermodifier = (memory.readword(0x7E03B6)*-1)
  715.     end
  716.     print("Star Meter Speed Mode is ON")
  717. else
  718.     starmetermodifier = 0
  719.     function starmeterspeed()
  720.     end
  721.     print("Star Meter Speed Mode is OFF")
  722. end
  723. -------------------------------------------------
  724. -------------------------------------------------
  725. if joypad.get(1)[DisableButton] ~= nil then
  726.     function DisableButtonFunction(button)
  727.         buttons_pressed = joypad.get(1)
  728.         buttons_pressed[button] = false
  729.         joypad.set(1, buttons_pressed)
  730.     end
  731.     print("Disable Button Mode is ON ", DisableButton)
  732. else
  733.     function DisableButtonFunction(button)
  734.     end
  735.     print("Disable Button Mode is OFF")
  736. end
  737. -------------------------------------------------
  738. -------------------------------------------------
  739. --------------------------------------------------- Goal stuff below
  740. ---------------------------------------------------
  741. --------------------------------------------------- Display functios and shit first yo
  742. ---------------------------------------------------
  743. ---------------------------------------------------
  744. y_offset = 4
  745. function display_goals_gen(goalstring ,x_collect, mingoal, maxgoal, mingoalboolean, maxgoalboolean, y_offset)
  746.     if  mingoalboolean == true then
  747.         if x_collect < mingoal then
  748.             color = "red"
  749.         else
  750.             color = "green"
  751.         end
  752.         minstring = " min: "
  753.     else
  754.         mingoal = ""
  755.         minstring = ""
  756.     end
  757.     if maxgoalboolean == true then
  758.         if x_collect == maxgoal then
  759.             color = "orange"
  760.         elseif mingoalboolean == false then
  761.             color = "yellow"
  762.         end
  763.         maxstring = " max: "
  764.     else
  765.         maxstring = ""
  766.         maxgoal = ""
  767.     end
  768. gui.text(4, y_offset, goalstring .. x_collect .. " -" .. minstring .. mingoal .. maxstring .. maxgoal, color)
  769. end
  770. ---------------------------------------------------
  771. if DisplayCoin == true and CoinGoals == true then
  772.     function coindisplay()
  773.         display_goals_gen("Coins: ", collectedcoins, MinCoinGoal, MaxCoinGoal, MinimumCoins, MaximumCoins, y_offset_coin)
  774.     end
  775.     y_offset_coin = y_offset
  776.     y_offset = y_offset + 8
  777. else
  778.     function coindisplay()
  779.     end
  780. end
  781. ---------------------------------------------------
  782. if DisplayStar == true and StarGoals == true then
  783.     function stardisplay()
  784.         display_goals_gen("Stars: ", collectedstars, MinStarGoal, MaxStarGoal, MinimumStars, MaximumStars, y_offset_star)
  785.     end
  786.     y_offset_star = y_offset
  787.     y_offset = y_offset + 8
  788. else
  789.     function stardisplay()
  790.     end
  791. end
  792. ---------------------------------------------------
  793. if DisplayFlower == true and FlowerGoals == true then
  794.     function flowerdisplay()
  795.         display_goals_gen("Flowers: ", flowers, MinFlowerGoal, MaxFlowerGoal, MinimumFlowers, MaximumFlowers, y_offset_flower)
  796.     end
  797.     y_offset_flower = y_offset
  798.     y_offset = y_offset + 8
  799. else
  800.     function flowerdisplay()
  801.     end
  802. end
  803. ---------------------------------------------------
  804. if DisplayRed == true and RedCoinGoals == true then
  805.     function reddisplay()
  806.         display_goals_gen("Red Coins: ", redcoins, MinRedCoinGoal, MaxRedCoinGoal, MinimumRedCoins, MaximumRedCoins, y_offset_red)
  807.     end
  808.     y_offset_red = y_offset
  809.     y_offset = y_offset + 8
  810. else
  811.     function reddisplay()
  812.     end
  813. end
  814. ---------------------------------------------------
  815. if DisplayJump == true and JumpGoals == true then
  816.     function jumpdisplay()
  817.         display_goals_gen("Jumped: ", times_jumped, MinJumpGoal, MaxJumpGoal, MinimumJumps, MaximumJumps, y_offset_jump)
  818.     end
  819.     y_offset_jump = y_offset
  820.     y_offset = y_offset + 8
  821. else
  822.     function jumpdisplay()
  823.     end
  824. end
  825. ---------------------------------------------------
  826. if DisplayEggs == true and Egg_Goals == true then
  827.     function eggdisplay()
  828.         display_goals_gen("Eggs: ", eggs_made, MinEggGoal, MaxEggGoal, MinimumEggs, MaximumEggs, y_offset_egg)
  829.     end
  830.     y_offset_egg = y_offset
  831.     y_offset = y_offset + 8
  832. else
  833.     function eggdisplay()
  834.     end
  835. end
  836. ---------------------------------------------------
  837. if DisplayFuzzy == true and Fuzzy_Goals == true then
  838.     function fuzdisplay()
  839.         display_goals_gen("Fuzzies: ", touched_fuzzies, MinFuzzyGoal, MaxFuzzyGoal, MinimumFuzzies, MaximumFuzzies, y_offset_fuz)
  840.     end
  841.     y_offset_fuz = y_offset
  842.     y_offset = y_offset + 8
  843. else
  844.     function fuzdisplay()
  845.     end
  846. end
  847. ---------------------------------------------------
  848. if DisplayLives == true and Lives_Goals == true then
  849.     function livesdisplay()
  850.         display_goals_gen("Lives: ", extralives_gathered, MinLivesGoal, MaxLivesGoal, MinimumLives, MaximumLives, y_offset_lives)
  851.     end
  852.     y_offset_lives = y_offset
  853.     y_offset = y_offset + 8
  854. else
  855.     function livesdisplay()
  856.     end
  857. end
  858. ---------------------------------------------------
  859. function what_to_display()
  860.     if gamemode == 15 then
  861.         coindisplay()
  862.         stardisplay()
  863.         flowerdisplay()
  864.         reddisplay()
  865.         jumpdisplay()
  866.         eggdisplay()
  867.         fuzdisplay()
  868.         livesdisplay()
  869.     end
  870. end
  871. gui.register(what_to_display)
  872. ---------------------------------------------------
  873. ---------------------------------------------------
  874. --------------------------------------------------- Start with goal functions.
  875. ---------------------------------------------------
  876. ---------------------------------------------------
  877. if MinimumCoins == true then
  878.     function mincoincheck()
  879.         if collectedcoins < MinCoinGoal then
  880.             if gamemode == 16 or memory.readbyte(0x7E004F) == 240 then
  881.                 firedeath()
  882.             end
  883.         end
  884.     end
  885. else
  886.     function mincoincheck()
  887.     end
  888. end
  889. ---------------------------------------------------
  890. if MaximumCoins == true then
  891.     function maxcoincheck()
  892.         if collectedcoins > MaxCoinGoal and memory.readbyte(0x7001AE) == 0 then
  893.             firedeath()
  894.             collectedcoins = 0
  895.         end
  896.     end
  897. else
  898.     function maxcoincheck()
  899.     end
  900. end
  901. ---------------------------------------------------
  902. lastframecoins = memory.readbyte(0x7E037B)
  903. collectedcoins = 0
  904. function coincounter()
  905.     gamemode = memory.readbyte(0x7E0118)
  906.     if memory.readbyte(0x7E037B) > lastframecoins then
  907.         collectedcoins = collectedcoins + memory.readbyte(0x7E037B) - lastframecoins
  908.     elseif memory.readbyte(0x7E037B) < lastframecoins then
  909.         collectedcoins = collectedcoins + 100 - lastframecoins + memory.readbyte(0x7E037B)
  910.     end
  911.     lastframecoins = memory.readbyte(0x7E037B)
  912. end
  913. ---------------------------------------------------
  914. if CoinGoals == true then
  915.     function coingoals()
  916.         savering = memory.readbyte(0x7E0B65)
  917.         coincounter()
  918.         if savering == 1 then
  919.             MidRingCoins = collectedcoins
  920.         end
  921.         if gamemode == 61 or gamemode == 34 then
  922.             collectedcoins = 0
  923.         end
  924.         if gamemode == 53 then
  925.             collectedcoins = MidRingCoins
  926.         end
  927.         mincoincheck()
  928.         maxcoincheck()
  929.     end
  930. else
  931.     function coingoals()
  932.     end
  933. end
  934.  
  935. ---------------------------------------------------
  936. ------------------------------------------------------
  937. ------------------------------------------------------
  938. ---------------------------------------------------
  939. lastframestars = math.floor(memory.readword(0x7E03B6)/10)
  940. collectedstars = 0
  941. if MinimumStars == true then
  942.     function minstarcheck()
  943.         if collectedstars < MinStarGoal then
  944.             if gamemode == 16 or memory.readbyte(0x7E004F) == 240 then
  945.                 firedeath()
  946.             end
  947.         end
  948.     end
  949. else
  950.     function minstarcheck()
  951.     end
  952. end
  953. ------------------------------------------------------
  954. if MaximumStars == true then
  955.     function maxstarcheck()
  956.         if collectedstars > MaxStarGoal and memory.readbyte(0x7001AE) == 0 then
  957.             firedeath()
  958.             collectedstars = 0
  959.         end
  960.     end
  961. else
  962.     function maxstarcheck()
  963.     end
  964. end
  965. ------------------------------------------------------
  966. function starcounter()
  967.     thisframestars = math.floor(memory.readword(0x7E03B6)/10)
  968.     gamemode = memory.readbyte(0x7E0118)
  969.     if thisframestars > lastframestars and gamemode == 15 then --
  970.         collectedstars = collectedstars + thisframestars - lastframestars
  971.     end
  972.     lastframestars = math.floor(memory.readword(0x7E03B6)/10)
  973. end
  974. ------------------------------------------------------
  975. if StarGoals == true then
  976.     function stargoals()
  977.         memory.writeword(0x7EE23C, 10000)
  978.         starcounter()
  979.         savering = memory.readbyte(0x7E0B65)
  980.         if savering == 1 then
  981.             MidRingStars = collectedstars
  982.         end
  983.         if gamemode == 61 or gamemode == 34  then
  984.             collectedstars = 0
  985.         end
  986.         if gamemode == 53 then
  987.             collectedstars = MidRingStars
  988.  
  989.         end
  990.         minstarcheck()
  991.         maxstarcheck()
  992.     end
  993. else
  994.     function stargoals()
  995.     end
  996. end
  997. ---------------------------------------------------
  998. ------------------------------------------------------
  999. ------------------------------------------------------
  1000. ---------------------------------------------------
  1001. if MinimumFlowers == true then
  1002.     function minflowers()
  1003.             if flowers < MinFlowerGoal then
  1004.                 if gamemode == 16  or memory.readbyte(0x7E004F) == 240 then
  1005.                     firedeath()
  1006.                 end
  1007.             end
  1008.     end
  1009. else
  1010.     function minflowers()
  1011.     end
  1012. end
  1013. ------------------------------------------------------
  1014. if MaximumFlowers == true then
  1015.     flowerdeath = false
  1016.     function maxflowers()
  1017.             if flowers > MaxFlowerGoal and memory.readbyte(0x7001AE) == 0 and flowerdeath == false and gamemode == 15 then
  1018.                 firedeath()
  1019.                 flowerdeath = true
  1020.             elseif gamemode == 12 and flowerdeath == true then
  1021.                 flowerdeath = false
  1022.             end
  1023.     end
  1024. else
  1025.     function maxflowers()
  1026.     end
  1027. end
  1028. ------------------------------------------------------
  1029. if FlowerGoals == true then
  1030.     function flowergoals()
  1031.         gamemode = memory.readbyte(0x7E0118)
  1032.         flowers = memory.readbyte(0x7E03B8)
  1033.         minflowers()
  1034.         maxflowers()
  1035.     end
  1036. else
  1037.     function flowergoals()
  1038.     end
  1039. end
  1040. ---------------------------------------------------
  1041. ------------------------------------------------------
  1042. ------------------------------------------------------
  1043. ---------------------------------------------------
  1044. if MinimumRedCoins == true then
  1045.     function minredcoins()
  1046.             if redcoins < MinRedCoinGoal then
  1047.                 if gamemode == 16  or memory.readbyte(0x7E004F) == 240 then
  1048.                     firedeath()
  1049.                 end
  1050.             end
  1051.     end
  1052. else
  1053.     function minredcoins()
  1054.     end
  1055. end
  1056. ------------------------------------------------------
  1057. if MaximumRedCoins == true then
  1058.     redcoindeath = false
  1059.     function maxredcoins()
  1060.             if redcoins > MaxRedCoinGoal and memory.readbyte(0x7001AE) == 0 and redcoindeath == false then
  1061.                 firedeath()
  1062.                 redcoindeath = true
  1063.             elseif gamemode == 12 and redcoindeath == true then
  1064.                 redcoindeath = false
  1065.             end
  1066.     end
  1067. else
  1068.     function maxredcoins()
  1069.     end
  1070. end
  1071. ------------------------------------------------------
  1072. if RedCoinGoals == true then
  1073.     function redcoingoals()
  1074.         gamemode = memory.readbyte(0x7E0118)
  1075.         redcoins = memory.readbyte(0x7E03B4)
  1076.         minredcoins()
  1077.         maxredcoins()
  1078.     end
  1079. else
  1080.     function redcoingoals()
  1081.     end
  1082. end
  1083. ---------------------------------------------------
  1084. ------------------------------------------------------
  1085. ------------------------------------------------------
  1086. ---------------------------------------------------
  1087. times_jumped = 0
  1088. function jumpcounter()
  1089.         soundtype = memory.readbyte(0x7E0055)
  1090.         if soundtype == 73 or soundtype == 56 then
  1091.             times_jumped = times_jumped + 1
  1092.         end
  1093. end
  1094. ------------------------------------------------------
  1095. if MinimumJumps == true then
  1096.     function minjumps()
  1097.             if times_jumped < MinJumpGoal then
  1098.                 if gamemode == 16  or memory.readbyte(0x7E004F) == 240 then
  1099.                     firedeath()
  1100.                 end
  1101.             end
  1102.     end
  1103. else
  1104.     function minjumps()
  1105.     end
  1106. end
  1107. ------------------------------------------------------
  1108. if MaximumJumps == true then
  1109.     function maxjumps()
  1110.             if times_jumped > MaxJumpGoal and memory.readbyte(0x7001AE) == 0 then
  1111.                 firedeath()
  1112.                 times_jumped = 0
  1113.             end
  1114.     end
  1115. else
  1116.     function maxjumps()
  1117.     end
  1118. end
  1119. ------------------------------------------------------
  1120. if JumpGoals == true then
  1121.     function jumpgoals()
  1122.         gamemode = memory.readbyte(0x7E0118)
  1123.         jumpcounter()
  1124.         savering = memory.readbyte(0x7E0B65)
  1125.         if savering == 1 then
  1126.             MidRingJumps = times_jumped
  1127.         end
  1128.         if gamemode == 61 or gamemode == 34  then
  1129.             times_jumped = 0
  1130.         end
  1131.         if gamemode == 53 then
  1132.             times_jumped = MidRingJumps
  1133.         end
  1134.         minjumps()
  1135.         maxjumps()
  1136.     end
  1137. else
  1138.     function jumpgoals()
  1139.     end
  1140. end
  1141. ---------------------------------------------------
  1142. ------------------------------------------------------------------------------------------------------------
  1143. ------------------------------------------------------------------------------------------------------------
  1144. ---------------------------------------------------
  1145. if MinimumEggs == true then
  1146.     function mineggs()
  1147.             if eggs_made < MinEggGoal then
  1148.                 if gamemode == 16  or memory.readbyte(0x7E004F) == 240 then
  1149.                     firedeath()
  1150.                 end
  1151.             end
  1152.     end
  1153. else
  1154.     function mineggs()
  1155.     end
  1156. end
  1157. ---------------------------------------------------
  1158. if MaximumEggs == true then
  1159.     function maxeggs()
  1160.             if eggs_made > MaxEggGoal and memory.readbyte(0x7001AE) == 0 then
  1161.                 firedeath()
  1162.                 eggs_made = 0
  1163.             end
  1164.     end
  1165. else
  1166.     function maxeggs()
  1167.     end
  1168. end
  1169. ---------------------------------------------------
  1170. eggs_made = 0
  1171. swallowing_egg = false
  1172. function enemies_swallowed_counter()
  1173.     if memory.readbyte(0x700150) == 71 and swallowing_egg == false then  -- Issue if you get hit while making an egg, might be others too? Also counts when eating a fuzzy. Need new indicator!
  1174.         eggs_made = eggs_made + 1
  1175.         swallowing_egg = true
  1176.     elseif memory.readbyte(0x700150) == 75 then
  1177.         swallowing_egg = false
  1178.     end
  1179. end
  1180. ---------------------------------------------------
  1181. if Egg_Goals == true then
  1182.     function eggoals()
  1183.         gamemode = memory.readbyte(0x7E0118)
  1184.         enemies_swallowed_counter()
  1185.         savering = memory.readbyte(0x7E0B65)
  1186.         if savering == 1 then
  1187.             MidRingEggs = eggs_made
  1188.         end
  1189.         if gamemode == 61 or gamemode == 34  then
  1190.             eggs_made = 0
  1191.         end
  1192.         if gamemode == 53 then
  1193.             eggs_made = MidRingEggs
  1194.         end
  1195.         mineggs()
  1196.         maxeggs()
  1197.     end
  1198. else
  1199.     function eggoals()
  1200.     end
  1201. end
  1202. ---------------------------------------------------
  1203. ------------------------------------------------------
  1204. ------------------------------------------------------
  1205. ---------------------------------------------------
  1206. touched_fuzzies = 0
  1207. function fuzzy_counter() -- very important that this is before drunk mode, else it won't work
  1208.     if memory.readword(0x701FE8) == 1024 and touched_fuzzy == false then
  1209.         touched_fuzzies = touched_fuzzies + 1
  1210.         touched_fuzzy = true
  1211.     elseif memory.readword(0x701FE8) < 1024 then
  1212.         touched_fuzzy = false
  1213.     end
  1214. end
  1215. ------------------------------------------------------
  1216. if MinimumFuzzies == true then
  1217.     function minfuzzies()
  1218.             if touched_fuzzies < MinFuzzyGoal then
  1219.                 if gamemode == 16  or memory.readbyte(0x7E004F) == 240 then
  1220.                     firedeath()
  1221.                 end
  1222.             end
  1223.     end
  1224. else
  1225.     function minfuzzies()
  1226.     end
  1227. end
  1228. ------------------------------------------------------
  1229. if MaximumFuzzies == true then
  1230.     function maxfuzzies()
  1231.             if touched_fuzzies > MaxFuzzyGoal and memory.readbyte(0x7001AE) == 0 then
  1232.                 firedeath()
  1233.                 touched_fuzzies = 0
  1234.             end
  1235.     end
  1236. else
  1237.     function maxfuzzies()
  1238.     end
  1239. end
  1240. ------------------------------------------------------
  1241. if Fuzzy_Goals == true then
  1242.     function fuzzygoals()
  1243.         gamemode = memory.readbyte(0x7E0118)
  1244.         fuzzy_counter()
  1245.         savering = memory.readbyte(0x7E0B65)
  1246.         if savering == 1 then
  1247.             MidRingFuzzies = touched_fuzzies
  1248.         end
  1249.         if gamemode == 61 or gamemode == 34  then
  1250.             touched_fuzzies = 0
  1251.         end
  1252.         if gamemode == 53 then
  1253.             touched_fuzzies = MidRingFuzzies
  1254.         end
  1255.         minfuzzies()
  1256.         maxfuzzies()
  1257.     end
  1258. else
  1259.     function fuzzygoals()
  1260.     end
  1261. end
  1262. ---------------------------------------------------
  1263. ------------------------------------------------------
  1264. ------------------------------------------------------
  1265. ---------------------------------------------------
  1266. current_extralives = memory.readword(0x7E0379)
  1267. extralives_gathered = 0
  1268. function extralives_counter()
  1269.     extralives_difference = memory.readword(0x7E0379) - current_extralives
  1270.     if extralives_difference > 0 then
  1271.         extralives_gathered = extralives_gathered + extralives_difference
  1272.     end
  1273.     current_extralives = memory.readword(0x7E0379)
  1274. end
  1275. ------------------------------------------------------
  1276. if MinimumLives == true then
  1277.     function minlives()
  1278.             if extralives_gathered < MinLivesGoal then
  1279.                 if gamemode == 16  or memory.readbyte(0x7E004F) == 240 then
  1280.                     firedeath()
  1281.                 end
  1282.             end
  1283.     end
  1284. else
  1285.     function minlives()
  1286.     end
  1287. end
  1288. ------------------------------------------------------
  1289. if MaximumLives == true then
  1290.     function maxlives()
  1291.             if extralives_gathered > MaxLivesGoal and memory.readbyte(0x7001AE) == 0 then
  1292.                 firedeath()
  1293.                 extralives_gathered = 0
  1294.             end
  1295.     end
  1296. else
  1297.     function maxlives()
  1298.     end
  1299. end
  1300. ------------------------------------------------------
  1301. if Lives_Goals == true then
  1302.     function livesgoals()
  1303.         gamemode = memory.readbyte(0x7E0118)
  1304.         extralives_counter()
  1305.         savering = memory.readbyte(0x7E0B65)
  1306.         if savering == 1 then
  1307.             MidRingLives = extralives_gathered
  1308.         end
  1309.         if gamemode == 61 or gamemode == 34  then
  1310.             extralives_gathered = 0
  1311.         end
  1312.         if gamemode == 53 then
  1313.             extralives_gathered = MidRingLives
  1314.         end
  1315.         minlives()
  1316.         maxlives()
  1317.     end
  1318. else
  1319.     function livesgoals()
  1320.     end
  1321. end
  1322. -------------------------------------------------
  1323. -------------------------------------------------
  1324. ------------------MAIN---------------------------
  1325. -------------------------------------------------
  1326. -------------------------------------------------
  1327. while true do
  1328. --
  1329.     LevelBlitz()
  1330.     -- Goal stuff
  1331.     coingoals()
  1332.     stargoals()
  1333.     flowergoals()
  1334.     redcoingoals()
  1335.     jumpgoals()
  1336.     eggoals()
  1337.     fuzzygoals()
  1338.     livesgoals()
  1339.     -- things
  1340.     starmeterspeed()
  1341.     packmule()
  1342.     noleft()
  1343.     DisableButtonFunction(DisableButton)
  1344.     drunk()
  1345.     hardmode()
  1346.     deathtimer()
  1347.     forceretry()
  1348.     infinitelives()
  1349.     extendedflutter()
  1350.     notongue()
  1351.     noflutter()
  1352.     velcromode()
  1353.     mouthmode()
  1354.     eggstransitions()
  1355.     fastmodex()
  1356.     fastmodey()
  1357.     poisoncoins()
  1358.     poisonflowers()
  1359.     groundislava()
  1360.     terminalmode()
  1361.     poisonair()
  1362.     coincounter()
  1363.     --
  1364.     emu.frameadvance()
  1365. end
  1366. -- END MAIN --
  1367. -- Made by Arnethegreat - message me on #yoshi @ irc.speeddemosarchive.com if you want anything
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement