Advertisement
MrTrala

ArcherU Combo (PRIV Version)

Sep 17th, 2016
886
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 22.54 KB | None | 0 0
  1. --[[
  2.     Combo Archer for ArchlightOnline
  3.     (Private Version)
  4.     By Mr Trala
  5.    
  6. Thanks to:
  7. Colandus from Otland for the string.explode function.
  8.  
  9. Instructions;
  10. Config your ManaRune, your HealCast and your ManaCast just below here, then
  11. load the script, the rest of the instructions are in the Archer Channel.
  12.  
  13.     Change Log;
  14.    
  15. 2.0.0 -- First stable full version. -- Public released.
  16. 2.0.1 -- Fixed the bug in "ComboAOE" where it wasn't counting correctly the monsters around (was using an old method, now #Self.GetTargets).
  17. 2.0.2 -- Added the module "AlarmL" a module to sound an alarm if you see a legendary monster.
  18. 2.0.3 -- Fixed problem after Archlight HP/Mana Update.
  19. 2.0.4 -- Added the module "ComboSD" a module to combo Gran Con, Cannon, Focused and SD.
  20. 2.0.5 -- Fixed a bug in the healer (Thx to Erma for reporting it).
  21. 2.0.6 -- Fixed a bug in the shooters.
  22. 2.0.7 -- Added the PickUP Module, useful to auti pick your MC tokens, etc.
  23. 2.0.8 -- Reworked the PickUP Module.
  24. 2.0.9 -- Fixed an error in the ComboAOE module.
  25. 2.1.0 -- Fixed an error in the Aim and Life Steal module.
  26. 2.1.1 -- ReWorked the ComboSD to work how it was supposed to.
  27. 2.1.2 -- Added EXP boosters Module, a module to use all EXP boost (Thanks Starkovonic for the idea).
  28. 2.1.3 -- Added Loot module, will pause cavebot when you're looting a monster (you need Shadow speed looter).
  29. 2.1.4 -- Added a ReOpener BP module, so you can keep looting after a kick.
  30. 2.1.5 -- Fixed some errors with Loot and BP module.
  31. 2.1.6 -- ReWorked BP Module.
  32. 2.1.7 -- Added an Anti Para.
  33. 2.1.8 -- ReWorked Life Steal.
  34. 2.1.9 -- Finished EXP MODULE.
  35. 2.2.0 -- Fixed a problem in Para Module.
  36. 2.2.1 -- Fixed a problem in EXP and Loot module.
  37. 2.2.2 -- Fixed a problem in the EXP Module.
  38. 2.2.3 -- Added the ComboPS and ComboP, which is the Prestige 3 combo with and without sd respectivelly.
  39. 2.2.4 -- Changed some things in Anti PARA module to Use if X prestige.
  40.  
  41. Buyers;
  42.  
  43. 2.0.4 -- ANON -- Asked for "ComboSD" module, given AlarmL and Fix for ComboAOE for free.
  44. 2.1.9 -- ANON -- Send the P3 version..
  45. 2.2.2 -- ANON -- Send the P3 version.
  46. 2.2.2 -- ANON -- Send the P3 version.
  47. ]]
  48.  
  49.  
  50.  
  51. version = '2.2.4(PV)'
  52.  
  53. config = {
  54.     ManaRune = 11632, -- ID of your manarune.
  55.     HealCAST = 95, -- x% hp to cast exura san.
  56.     ManaCAST = 90, -- x% mana to use manarune.
  57.     SDID = 3154, -- ID of your SD, you NEED the donor SD or holyshock to use ComboSD, otherwise isnt gonna work.
  58.    
  59.     --Prestige Config
  60.     PrestigeNum = 3, -- Put your prestige here, 0 if you're not prestiged.
  61.    
  62.     -- EXP Module config.
  63.     ExpUS = 120, -- Time (in seconds) to Re-Use your scrolls (EXP MODULE).
  64.    
  65.     -- Config for PickUP module.
  66.     itemID = {11455, 8828, 8829,
  67.     21747, 9697, 12803,
  68.     3154, 5785, 9222,
  69.     2856, 3580, 16129, 3232,
  70.     5785, 9586, 939,
  71.     20270, 2968, 5922,
  72.     942, 5953, 8764,
  73.     12724, 20138, 9586,
  74.     19216, 19218},   -- ItemIDs to be picked up
  75.     containerName = "backpack",  -- Ex. "Purple Backpack", "Backpack of holding", "Bag" etc
  76.     CheckPOS = 1 -- The SQM from your character to check if theres an item.
  77.    
  78. }
  79.  
  80. spells = {
  81.     -- Exaus
  82.     FocusedEX = 'exevo gran mas flam', -- Focused shot
  83.     CannoEX = 'exevo vis hur', -- Energy Cannon
  84.     WavesEX = 'exevo dis flam hur', -- Sprays Exaus
  85.     PinPoEX = 'exevo gran mas flam', -- Pinpoint Shot
  86.     PerfectEX = 'utori pox', -- Perfect Shot
  87.    
  88.     -- Words
  89.     FocusedWD = 'Focused Shot',
  90.     GranConWD = 'Exori Gran Con',
  91.     ConWD = 'Energy Cannon',
  92.     PinWD = 'Pinpoint Shot',
  93.     PerfectWD = 'Perfect Shot',
  94.    
  95.     --Sprays
  96.     ESpray = 'Earth Arrow Spray',
  97.     ISpray = 'Ice Arrow Spray',
  98.     FSpray = 'Flame Arrow Spray',
  99.     ENSpray =  'Energy Arrow Spray'
  100. }
  101.  
  102. scrolls = {}
  103. scrolls[1] = {ItemID = 8764} -- 10% Scroll.
  104. scrolls[2] = {ItemID = 3020} -- 100% Boost.
  105. scrolls[3] = {ItemID = 19109} -- EXP Elixir.
  106. scrolls[4] = {ItemID = 5953} -- Marijuana.
  107. scrolls[5] = {ItemID = 3232} -- 30% Scroll.
  108. scrolls[6] = {ItemID = 8176} -- 50% Scroll.
  109.  
  110. names =
  111. {
  112. {Name = Self.Name()}
  113. }
  114.  
  115. for _, name in ipairs(names) do
  116.     if Self.Name() == name.Name then
  117.         print('Welcome to the Archer Combo Script '..name.Name..'.\n'..
  118.         'You are using the version '..version..'.\n'..
  119.         'Have fun!')
  120.         wait(5000)
  121.     end
  122. end
  123.  
  124. function string.trim(str)
  125.     return (str:gsub("^%s*(.-)%s*$", "%1"))
  126. end
  127.  
  128. function string.explode(str, sep, limit)
  129.     if limit and type(limit) ~= 'number' then
  130.         error("string.explode: limit must be a number", 2)
  131.     end
  132.  
  133.     if #sep == 0 or #str == 0 then return end
  134.     local pos, i, t = 1, 1, {}
  135.     for s, e in function() return str:find(sep, pos) end do
  136.         table.insert(t, str:sub(pos, s-1):trim())
  137.         pos = e + 1
  138.         i = i + 1
  139.         if limit and i == limit then break end
  140.     end
  141.     table.insert(t, str:sub(pos):trim())
  142.     return t
  143. end
  144.  
  145. spray = {}
  146. x = config
  147. sc = Self.GetSpellCooldown
  148. function onSpeak(channel, message)
  149.     -- receives the channel object that called it and the message that was inputted.
  150.     if (message == '/list') then
  151.         channel:SendYellowMessage('List of Modules', '\n'..
  152.         'Combo -- Use this one to start the basic combo script, "focused shot, exori gran con and energy cannon".\n'..
  153.         'ComboW -- Same as combo but without Energy Cannon (not "new" spell).\n'..
  154.         'ComboA -- This one will shot an Arrow Spray spell, config which one like this "ComboA, earth" (earth, ice, flame and energy).\n'..
  155.         'Aim -- Auto Aim spell (enabled by default).\n'..
  156.         'Manarune -- Auto use your manarune (enabled by default).\n'..
  157.         'LifeSteal -- LifeSteal renew (enabled by default, to stop it write /list LifeSteal).\n'..
  158.         'AlarmL -- a module to sound an alarm if you see a legendary monster.\n'..
  159.         'ComboSD -- a module to combo with cannon, gran con, focused and sd.\n'..
  160.         'PickUP -- a module to pick up everything you want, useful to pick the tokens from your MCS.\n'..  
  161.         'Exp -- a module to use your exp scrolls (all of them) write "/list exp" for more info(BETA).\n'..
  162.         'Loot -- a module that will pause cavebot when you are looting a monster (you need Shadow speed looter).\n'..
  163.         'BPS -- Auto opens the main BP so you can keep looting after a kick (Enabled by Default, to stop it write /list BPS).\n'..
  164.         'ComboP -- Prestige 3 Combo (only for archers with prestige 3 or more) WITHOUT SD!.\n'..
  165.         'ComboPS -- Prestige 3 Combo (only for archers with prestige 3 or more) WITH SD!.\n'..
  166.         'Train -- Use this one to start the training module (exura san + utana vid).\n')
  167.     end
  168.    
  169.     -- Modules
  170.     if (message == '/start Combo') or (message == 'Combo') or (message == 'combo') then
  171.         Module.Start('Combo')
  172.         channel:SendYellowMessage('Mr Trala', 'The module with the name "Combo" has been started.')
  173.        
  174.     elseif (message == '/stop Combo') or (message == '/stop combo') then
  175.         Module.Stop('Combo')
  176.         channel:SendRedMessage('Mr Trala', 'The module with the name "Combo" has been stopped.')
  177.        
  178.     elseif (message == '/start ComboW') or (message == 'ComboW') or (message == 'combow') then
  179.         Module.Start('ComboW')
  180.         channel:SendYellowMessage('Mr Trala', 'The module with the name "ComboW" has been started.')
  181.    
  182.     elseif (message == '/stop ComboW') or (message == '/stop combow') then
  183.         Module.Stop('ComboW')
  184.         channel:SendRedMessage('Mr Trala', 'The module with the name "ComboW" has been stopped.')
  185.        
  186.     elseif (message == '/start Aim') or (message == 'Aim') or (message == 'aim') then
  187.         Module.Start('Aim')
  188.         channel:SendYellowMessage('Mr Trala', 'The module with the name "Aim" has been started.')
  189.    
  190.     elseif (message == '/stop Aim') or (message == '/stop aim')then
  191.         Module.Stop('Aim')
  192.         channel:SendRedMessage('Mr Trala', 'The module with the name "Aim" has been stopped.')
  193.  
  194.     elseif (message == '/start Train') or (message == 'Train') or (message == 'train') then
  195.         Module.Start('Train')
  196.         channel:SendYellowMessage('Mr Trala', 'The module with the name "Train" has been started.')
  197.        
  198.     elseif (message == '/stop Train') or (message == '/stop train') then
  199.         Module.Stop('Train')
  200.         channel:SendRedMessage('Mr Trala', 'The module with the name "Train" has been stopped.')
  201.        
  202.     elseif (message == '/start Manarune') or (message == 'manarune') or (message == 'mr') then
  203.         Module.Start('Manarune')
  204.         channel:SendYellowMessage('Mr Trala', 'The module with the name "Manarune" has been started.')
  205.        
  206.     elseif (message == '/stop Manarune') or (message == '/stop train') then
  207.         Module.Stop('Manarune')
  208.         channel:SendRedMessage('Mr Trala', 'The module with the name "Manarune" has been stopped.')
  209.        
  210.     elseif (message == '/stop ComboA') or (message == '/stop comboa') then
  211.         Module.Stop('ComboAOE')
  212.         channel:SendRedMessage('Mr Trala', 'The module with the name "ComboAOE" has been stopped.')
  213.        
  214.        
  215.     elseif (message == '/start AlarmL') or (message == 'AlarmL') or (message == 'alarml') then
  216.         Module.Start('AlarmL')
  217.         channel:SendYellowMessage('Mr Trala', 'The module with the name "AlarmL" has been started.')
  218.        
  219.     elseif (message == '/stop AlarmL') or (message == '/stop alarml') then
  220.         Module.Stop('AlarmL')
  221.         channel:SendRedMessage('Mr Trala', 'The module with the name "AlarmL" has been stopped.')
  222.        
  223.     elseif (message == '/start ComboSD') or (message == 'ComboSD') or (message == 'combosd') then
  224.         Module.Start('ComboSD')
  225.         channel:SendYellowMessage('Mr Trala', 'The module with the name "ComboSD" has been started.')
  226.        
  227.     elseif (message == '/stop ComboSD') or (message == '/stop combosd') then
  228.         Module.Stop('ComboSD')
  229.         channel:SendRedMessage('Mr Trala', 'The module with the name "ComboSD" has been stopped.')
  230.        
  231.     elseif (message == '/start PickUP') or (message == 'PickUP') or (message == 'pickup') then
  232.         Module.Start('PickUP')
  233.         channel:SendYellowMessage('Mr Trala', 'The module with the name "PickUP" has been started.')
  234.        
  235.     elseif (message == '/stop PickUP') or (message == '/stop pickup') then
  236.         Module.Stop('PickUP')
  237.         channel:SendRedMessage('Mr Trala', 'The module with the name "PickUP" has been stopped.')  
  238.        
  239.     elseif (message == '/start EXP') or (message == 'EXP') or (message == 'exp') then
  240.         Module.Start('EXP')
  241.         channel:SendYellowMessage('Mr Trala', 'The module with the name "EXP" has been started.')
  242.        
  243.     elseif (message == '/stop EXP') or (message == '/stop exp') then
  244.         Module.Stop('EXP')
  245.         channel:SendRedMessage('Mr Trala', 'The module with the name "EXP" has been stopped.')
  246.  
  247.     elseif (message == '/start Loot') or (message == 'Loot') or (message == 'loot') then
  248.         Module.Start('Looting')
  249.         channel:SendYellowMessage('Mr Trala', 'The module with the name "Looting" has been started.')
  250.        
  251.     elseif (message == '/stop Loot') or (message == '/stop loot') then
  252.         Module.Stop('Looting')
  253.         channel:SendRedMessage('Mr Trala', 'The module with the name "Looting" has been stopped.')
  254.        
  255.     elseif (message == '/start ComboPS') or (message == 'ComboPS') or (message == 'combops') then
  256.         Module.Start('ComboPS')
  257.         channel:SendYellowMessage('Mr Trala', 'The module with the name "ComboPS" has been started.')
  258.        
  259.     elseif (message == '/stop ComboPS') or (message == '/stop combops') then
  260.         Module.Stop('ComboPS')
  261.         channel:SendRedMessage('Mr Trala', 'The module with the name "ComboPS" has been stopped.')
  262.        
  263.     elseif (message == '/start ComboP') or (message == 'ComboP') or (message == 'combop') then
  264.         Module.Start('ComboP')
  265.         channel:SendYellowMessage('Mr Trala', 'The module with the name "ComboP" has been started.')
  266.        
  267.     elseif (message == '/stop ComboP') or (message == '/stop combop') then
  268.         Module.Stop('ComboP')
  269.         channel:SendRedMessage('Mr Trala', 'The module with the name "ComboP" has been stopped.')
  270.                
  271.     elseif (message == '/list BPS') or (message == '/list bps') then
  272.         channel:SendRedMessage('Mr Trala', 'To stop this module you need to search in the script the followin: registerEventListener(TIMER_TICK, "BPS")\n'..
  273.         'Then delete it, save and reaload the script.\n')
  274.        
  275.     elseif (message == '/list LifeSteal') or (message == '/list lifesteal') then
  276.         channel:SendRedMessage('Mr Trala', 'To stop this module you need to search in the script the followin: registerEventListener(TIMER_TICK, "LifeSteal")\n'..
  277.         'Then delete it, save and reaload the script.\n')
  278.        
  279.     elseif (message == '/list exp') then
  280.         channel:SendOrangeMessage('Mr Trala', 'The module will try to use your exp scroll only IF they are in an opened backpack, so\n'..
  281.         'If you have 100% booster but you DONT want to use it, leave it in a closed BP, otherwise it will try to use it.\n')
  282.     end
  283.    
  284.     -- ComboAOE Module
  285.     if (message >= 'ComboA') and string.find(message, "ComboA") then
  286.     local p = string.explode(message, ",")
  287.         if p[2] == '' or not string.find(message, ",") then
  288.             channel:SendRedMessage('Mr Trala', 'Please config which Spray to use like this "ComboA, earth" (earth, ice, flame and energy).')
  289.            
  290.         elseif p[2] == '' or string.find(message, "%d") then
  291.             channel:SendRedMessage('Mr Trala', 'Please config which Spray to use like this "ComboA, earth" (earth, ice, flame and energy).')
  292.            
  293.         else   
  294.             spray = {}
  295.             spray[#spray+1] = {SioT = p[2]}
  296.             Module.Start('ComboAOE')
  297.             channel:SendYellowMessage('Mr Trala', 'The module with the name "ComboAOE" has been started and is going to use '..p[2]..' spray.')
  298.         end
  299.     end
  300. end
  301.  
  302. function ReOpen()
  303. local customChannel = Channel.New('Archer Channel', onSpeak, onClose)
  304. customChannel:SendYellowMessage('Mr Trala', 'Welcome to the Archer Combo Script, configured specifically for ArchlightOnline.\n'..
  305.         'This Script has been made by Mr Trala, and you are using the Version '..version..'\n'..
  306.         'If you found any bug send a message to Mr Trolo or Mr Ponid in Archlight.\n')
  307. customChannel:SendOrangeMessage('Instructions', '\n'..
  308.         'Write /list if you want to see a list of the modules you can use\n'..
  309.         'You can start or stop a Module with the command /start or /stop\n')
  310. end
  311.  
  312.  
  313. function onClose(channel)
  314.      -- receives the channel object that called it
  315.      print('To close '..channel:Name()..' you need to kill the script.')
  316.      ReOpen()
  317. end
  318.  
  319.  
  320. local customChannel = Channel.New('Archer Channel', onSpeak, onClose)
  321. customChannel:SendYellowMessage('Mr Trala', 'Welcome to the Archer Combo Script, configured specifically for ArchlightOnline.\n'..
  322.         'This Script has been made by Mr Trala, and you are using the Version '..version..'\n'..
  323.         'If you found any bug send a message to Mr Trolo or Mr Ponid in Archlight.\n')
  324. customChannel:SendOrangeMessage('Instructions', '\n'..
  325.         'Write /list if you want to see a list of the modules you can use\n'..
  326.         'You can start or stop a Module with the command /start or /stop\n')
  327.        
  328. -- Functions of the script.
  329. function PickUP()
  330. local p = Self.Position()
  331. local Cont = Container.New(x.containerName)
  332.     if (Self.Cap() >= 1) then
  333.         for y = -x.CheckPOS, x.CheckPOS do
  334.             for x = -x.CheckPOS, x.CheckPOS do
  335.                 if table.contains(config.itemID, Map.GetTopUseItem(p.x + x, p.y + y, p.z).id) then
  336.                     Map.PickupItem(p.x+x, p.y+y, p.z, Cont:Index(), 0)
  337.                 end
  338.                
  339.                 if (Cont:ItemCount() == Cont:ItemCapacity()) then
  340.                         local openAt = Cont:ItemCount() - 1
  341.                     if (Item.isContainer(Cont:GetItemData(openAt).id)) then
  342.                         Cont:UseItem(openAt, true)
  343.                     end
  344.                 end
  345.             end
  346.         end
  347.     end
  348. end
  349.  
  350. function Combo()
  351. local creature = Creature.GetByID(Self.TargetID())
  352.     if creature:isValid() and creature:isAlive()  and creature:isTarget() and creature:DistanceFromSelf() <= 6 and Self.Mana() >= 1 then
  353.         if Self.GetSpellCooldown(spells.FocusedEX) >= 1 and Self.GetSpellCooldown(spells.GranConWD) >= 1 and Self.GetSpellCooldown(spells.CannoEX) == 0 then
  354.             Self.Cast(spells.ConWD)
  355.             Manarune2()
  356.            
  357.         elseif Self.GetSpellCooldown(spells.FocusedEX) == 0 then
  358.             Self.Cast(spells.FocusedWD)
  359.             Manarune2()
  360.        
  361.         elseif Self.GetSpellCooldown(spells.FocusedEX) >= 1  and Self.GetSpellCooldown(spells.GranConWD) == 0 then
  362.             Self.Cast(spells.GranConWD)
  363.             Manarune2()
  364.         end
  365.     end
  366. end
  367.  
  368. function ComboW()
  369. local creature = Creature.GetByID(Self.TargetID())
  370.     if creature:isValid() and creature:isAlive()  and creature:isTarget() and creature:DistanceFromSelf() <= 6 and Self.Mana() >= 1 then           
  371.         if Self.GetSpellCooldown(spells.FocusedEX) == 0 then
  372.             Self.Cast(spells.FocusedWD)
  373.             Manarune2()
  374.        
  375.         elseif Self.GetSpellCooldown(spells.FocusedEX) >= 1  and Self.GetSpellCooldown(spells.GranConWD) == 0 then
  376.             Self.Cast(spells.GranConWD)
  377.             Manarune2()
  378.         end
  379.     end
  380. end
  381.  
  382. exaus = 0
  383.  
  384. function ComboAOE()
  385.     for i = 1, #spray do
  386. local f = spray[i]
  387. local shot = f.SioT
  388. local earth = spells.ESpray
  389. local ice = spells.ISpray
  390. local flame = spells.FSpray
  391. local energy = spells.ENSpray
  392. local creature = Creature.GetByID(Self.TargetID())
  393.         if creature:isValid() and creature:isAlive()  and creature:isTarget() and creature:DistanceFromSelf() <= 6 and (#Self.GetTargets(3)) <= 2 and Self.Mana() >= 1 then        
  394.             if Self.GetSpellCooldown(spells.FocusedEX) == 0 then
  395.                 Self.Cast(spells.FocusedWD)
  396.                 Manarune2()
  397.            
  398.             elseif Self.GetSpellCooldown(spells.FocusedEX) >= 1  and Self.GetSpellCooldown(spells.GranConWD) == 0 and (#Self.GetTargets(3)) <= 2 then
  399.                 Self.Cast(spells.GranConWD)
  400.                 Manarune2()
  401.             end
  402.         end
  403.  
  404.         if (#Self.GetTargets(3)) >= 3 and string.find(shot, "flame") and os.time() - exaus >= math.random(2.03, 2.1) and Self.Mana() >= 1 and creature:isTarget() then
  405.             Self.Cast(flame)
  406.             exaus = os.time()  
  407.            
  408.         elseif (#Self.GetTargets(3)) >= 3 and string.find(shot, "ice") and os.time() - exaus >= math.random(2.03, 2.1) and Self.Mana() >= 1 and creature:isTarget() then
  409.             Self.Cast(ice)
  410.             exaus = os.time()
  411.            
  412.         elseif (#Self.GetTargets(3)) >= 3 and string.find(shot, "energy") and os.time() - exaus >= math.random(2.03, 2.1) and Self.Mana() >= 1 and creature:isTarget() then
  413.             Self.Cast(energy)
  414.             exaus = os.time()
  415.            
  416.         elseif (#Self.GetTargets(3)) >= 3 and string.find(shot, "earth") and os.time() - exaus >= math.random(2.03, 2.1) and Self.Mana() >= 1 and creature:isTarget() then
  417.             Self.Cast(earth)
  418.             exaus = os.time()
  419.         end
  420.     end
  421. end
  422.  
  423. function ComboSD()
  424. local creature = Creature.GetByID(Self.TargetID())
  425.     if creature:isValid() and creature:isAlive()  and creature:isTarget() and creature:DistanceFromSelf() <= 6 and Self.Mana() >= 1 then
  426.         if Self.GetSpellCooldown(spells.FocusedEX) >= 1 and Self.GetSpellCooldown(spells.GranConWD) >= 1 and Self.GetSpellCooldown(spells.CannoEX) == 0 then
  427.             wait(500, 1050)
  428.             Self.UseItemWithTarget(x.SDID)
  429.             Self.Say(spells.ConWD)
  430.             Manarune2()
  431.             wait(1000)
  432.            
  433.         elseif Self.GetSpellCooldown(spells.FocusedEX) == 0 then
  434.             wait(500, 1050)
  435.             Self.UseItemWithTarget(x.SDID)
  436.             Self.Say(spells.FocusedWD)
  437.             Manarune2()
  438.             wait(1000)
  439.        
  440.         elseif Self.GetSpellCooldown(spells.FocusedEX) >= 1  and Self.GetSpellCooldown(spells.GranConWD) == 0 then
  441.             wait(500, 1050)
  442.             Self.UseItemWithTarget(x.SDID)
  443.             Self.Cast(spells.GranConWD)
  444.             Manarune2()
  445.             wait(1000)
  446.         end
  447.     end
  448. end
  449.  
  450. function ComboPS()
  451. local c = Creature.GetByID(Self.TargetID())
  452.     if c:isValid() and c:isAlive() and c:isTarget() and c:DistanceFromSelf() <= 6 and Self.Mana() >= 5 then
  453.         if sc(spells.PinPoEX) == 0 then
  454.             Self.UseItemWithTarget(x.SDID)
  455.             Manarune2()
  456.             Self.Say(spells.PinWD)
  457.            
  458.            
  459.         elseif sc(spells.PinPoEX) >= 1 and sc(spells.PerfectEX) == 0 then
  460.             Self.UseItemWithTarget(x.SDID)
  461.             Manarune2()
  462.             Self.Say(spells.PerfectWD)
  463.            
  464.         elseif sc(spells.PinPoEX) >= 1 and sc(spells.PerfectEX) >= 1 and sc(spells.GranConWD) == 0 then
  465.             Self.UseItemWithTarget(x.SDID)
  466.             Manarune2()
  467.             Self.Say(spells.GranConWD)
  468.         end
  469.     end
  470. end
  471.  
  472. function ComboP()
  473. local c = Creature.GetByID(Self.TargetID())
  474.     if c:isValid() and c:isAlive() and c:isTarget() and c:DistanceFromSelf() <= 6 and Self.Mana() >= 5 then
  475.         if sc(spells.PinPoEX) == 0 then
  476.             Manarune2()
  477.             Self.Say(spells.PinWD)
  478.                    
  479.         elseif sc(spells.PinPoEX) >= 1 and sc(spells.PerfectEX) == 0 then
  480.             Manarune2()
  481.             Self.Say(spells.PerfectWD)
  482.            
  483.         elseif sc(spells.PinPoEX) >= 1 and sc(spells.PerfectEX) >= 1 and sc(spells.GranConWD) == 0 then
  484.             Manarune2()
  485.             Self.Say(spells.GranConWD)
  486.         end
  487.     end
  488. end
  489.  
  490. function Train()
  491.     local spell = "exura san"
  492.     local spell2 = "utana vid"
  493.         if Self.GetSpellCooldown(spell) == 0 and (Self.Mana()>= 10) then
  494.             Self.Say(spell)
  495.         end
  496.        
  497.         if Self.GetSpellCooldown(spell2) == 0 and (Self.Mana()>= 10) then
  498.             Self.Say(spell2)
  499.         end
  500. end
  501.  
  502. function Manarune2()
  503.     if Self.Health() <= config.HealCAST then
  504.         Self.UseItem(config.ManaRune)
  505.         Self.Say('exura san')
  506.         wait(200, 400)
  507.     end
  508.    
  509.     if Self.Mana() <= config.ManaCAST and Self.Health() >= config.HealCAST then
  510.         Self.UseItem(config.ManaRune)
  511.         wait(400, 600)
  512.     end
  513. end
  514.  
  515. function AlarmL()
  516. local am = 0
  517.     for name, c in Creature.iMonsters(3) do
  518.         if c:isValid() and c:isAlive() and not Self.isInPz() and c:isOnScreen() and c:Skull() == 4 then
  519.             am = am +1
  520.         end
  521.        
  522.         if am >= 1 then
  523.             alert()
  524.             wait(1000)
  525.         end
  526.     end
  527. end
  528.  
  529. Module('EXP', function(Mod)
  530.     for i = 1, #scrolls do
  531.     local t = scrolls[i]
  532.         if Self.ItemCount(t.ItemID) >= 1 then
  533.             Self.UseItemWithMe(t.ItemID)
  534.             wait(100)
  535.             Self.UseItem(t.ItemID)
  536.             Manarune2()
  537.         end
  538.     end
  539. Mod:Delay((config.ExpUS * 1000), (config.ExpUS * 1000) + 200)
  540. end, false)
  541.  
  542.  
  543. Module.New('Looting', function(Mod)
  544. local exaus = 2
  545.     if (#Self.GetTargets(3)) >= 1 then
  546.         Walker.Stop()
  547.     else
  548.         wait(3000)
  549.         Walker.Start()
  550.     end
  551. Mod:Delay((exaus * 1000), (exaus * 1000) + 200)
  552. end, false)
  553.  
  554. function BPS()
  555. local Op = Container(0)
  556.     if not Op:isOpen() then
  557.         Self.OpenMainBackpack(false)
  558.     end
  559. end
  560.  
  561. function Paraz()
  562.     if Self.isParalyzed() == true and Self.Mana() >= 5 and x.PrestigeNum >= 2   then
  563.         Self.Say("Improved Utani Hur")
  564.        
  565.     elseif Self.isParalyzed() == true and Self.Mana() >= 5 and PrestigeNum <= 1 then
  566.         Self.Say("Utani Hur")
  567.     end
  568. end
  569.  
  570. function LifeSteal()
  571. local exaus = 'exura gran ico'
  572.         if Self.GetSpellCooldown(exaus) == 0 then
  573.             Self.Cast('Life Steal')
  574.             Manarune2()
  575.         end
  576. end
  577.  
  578. registerEventListener(TIMER_TICK, "LifeSteal")
  579. registerEventListener(TIMER_TICK, "Paraz")
  580. registerEventListener(TIMER_TICK, "BPS")
  581. Module('Combo', Combo, false)
  582. Module('ComboW', ComboW, false)
  583. Module('Train', Train, false)
  584. Module('ComboAOE', ComboAOE, false)
  585. Module('AlarmL', AlarmL, false)
  586. Module('ComboSD', ComboSD, false)
  587. Module('PickUP', PickUP, false)
  588. Module('ComboPS', ComboPS, false)
  589. Module('ComboP', ComboP, false)
  590.  
  591. function AimT()
  592. local mana = 5
  593.         if(Self.Mana() >= mana) then
  594.             Self.Cast("Aim")
  595.         end
  596. end
  597.  
  598. Module.New('Aim', function(Mod)
  599. local exaus = 9
  600.         if Self.CanCastSpell('Utani Hur') then
  601.             AimT()
  602.             Manarune2()
  603.             Mod:Delay((exaus * 1000), (exaus * 1000) + 200)
  604.         end
  605. end, true)
  606.  
  607. Module('Manarune', function(mod)
  608.         if Self.Health() <= config.HealCAST then
  609.             Self.UseItem(config.ManaRune)
  610.             Self.Say('exura san')
  611.             wait(200, 400)
  612.         end
  613.        
  614.         if Self.Mana() <= config.ManaCAST and Self.Health() >= config.HealCAST then
  615.             Self.UseItem(config.ManaRune)
  616.             wait(400, 600)
  617.         end
  618. end, true)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement