16HeX16

Plugin - Kayle

Jul 1st, 2013
562
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.50 KB | None | 0 0
  1. if myHero.charName ~= "Kayle" then return end
  2.  
  3. function PluginOnLoad()
  4.     mainLoad()
  5.     mainMenu()
  6. end
  7.  
  8. function PluginOnTick()
  9.     Checks()
  10.     if Target and (Menu2.AutoCarry or Menu2.MixedMode) then
  11.         if EREADY and Menu.useE and GetDistance(Target) < eRange then
  12.             CastSpell(_E)
  13.         end
  14.         if QREADY and Menu.useQ and GetDistance(Target) < qRange then
  15.             CastSpell(_Q, Target)
  16.         end
  17.         if WREADY and Menu.useW and GetDistance(Target) > wBuffer then
  18.             CastSpell(_W, myHero)
  19.         end
  20.     end
  21. end
  22.  
  23. function PluginOnDraw()
  24.     if Menu.drawQ and not myHero.dead then
  25.         DrawCircle(myHero.x, myHero.y, myHero.z, qRange, 0xFF80FF00)
  26.     end
  27. end
  28.  
  29. --> Checks
  30. function Checks()
  31.     Target = AutoCarry.GetAttackTarget()
  32.     QREADY = (myHero:CanUseSpell(_Q) == READY)
  33.     WREADY = (myHero:CanUseSpell(_W) == READY)
  34.     EREADY = (myHero:CanUseSpell(_E) == READY)
  35. end
  36.  
  37. --> Main Load
  38. function mainLoad()
  39.     AutoCarry.SkillsCrosshair.range = 1050
  40.     qRange, wBuffer, eRange = 650, 400, 525
  41.     QREADY, WREADY, EREADY = false, false, false
  42.     Menu = AutoCarry.PluginMenu
  43.     Menu2 = AutoCarry.MainMenu
  44. end
  45.  
  46. function mainMenu()
  47.     Menu:addParam("sep", "-- Cast Options --", SCRIPT_PARAM_INFO, "")
  48.     Menu:addParam("useQ", "Use - Reckoning", SCRIPT_PARAM_ONOFF, true)
  49.     Menu:addParam("useW", "Use - Divine Blessing", SCRIPT_PARAM_ONOFF, true)
  50.     Menu:addParam("useE", "Use - Righteous Fury", SCRIPT_PARAM_ONOFF, true)
  51.     Menu:addParam("sep1", "-- Draw Options --", SCRIPT_PARAM_INFO, "")
  52.     Menu:addParam("drawQ", "Draw - Reckoning", SCRIPT_PARAM_ONOFF, false)
  53. end
Advertisement
Add Comment
Please, Sign In to add comment