Guest User

Alistar V2.2

a guest
Aug 30th, 2014
354
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 4.25 KB | None | 0 0
  1. -- MADE IN POLAND
  2.  
  3. if myHero.charName ~= "Alistar" then return end
  4.  
  5. local ts
  6. local version = 2.2
  7. local DFG = GetInventorySlotItem(3128) -- Deathfire Grasp
  8.  
  9. function OnLoad()
  10.     PrintChat("<font color=\"#ff9e00\">[NECEK CARRY]</font> <font color=\"#00ff00\">Combo Alistar! Have fun! By necek123. (V"..version..")</font>")
  11.     ts = TargetSelector(TARGET_LESS_CAST_PRIORITY, 650, DAMAGE_MAGIC, true)
  12.     menu()
  13. end
  14.  
  15. function OnTick()
  16.     ts:update()
  17.     podazanie()
  18.     fullcombo()
  19.     autoe()
  20.     dfg()
  21.     autoesojusznicy()
  22. end
  23.  
  24. function OnDraw()
  25.     if (Alistar.otoczka) then
  26.         DrawCircle(myHero.x, myHero.y, myHero.z, 650, ARGB(102, 255, 102, 102))
  27.     end
  28.    
  29.     if (Alistar.otoczkaq) then
  30.         DrawCircle(myHero.x, myHero.y, myHero.z, 365, ARGB(33, 25, 4, 54))
  31.     end
  32.    
  33.     if (Alistar.otoczkae) then
  34.         DrawCircle(myHero.x, myHero.y, myHero.z, 575, ARGB(33, 25, 4, 54))
  35.     end
  36.     autoe()
  37. end
  38.  
  39. -- COMBO SPACE ==============================
  40.  
  41.  
  42. function fullcombo()
  43.     if (Alistar.combo) then
  44.         if (ts.target ~= nil) then
  45.             if (GetDistance(ts.target) <= 365) then
  46.                 if (myHero:CanUseSpell(_Q) == READY) then
  47.                     CastSpell(_Q)
  48.                 end
  49.             else
  50.                 if (myHero:CanUseSpell(_W and _Q) == READY) then
  51.                     if (GetDistance(ts.target) <= 650) then
  52.                         CastSpell(_W, ts.target)
  53.                         podrzutq()
  54.                     end
  55.                 end
  56.             end
  57.         end
  58.     end
  59. end
  60.  
  61. function podrzutq()
  62.                 if (GetDistance(ts.target) <= 365) then
  63.                     if (myHero:CanUseSpell(_Q) == READY) then
  64.                         CastSpell(_Q)
  65.                 end
  66.         end
  67.     end
  68. -- RANDOM OPTIONS ====================
  69.  
  70. function podazanie()
  71.     if (Misc.podazanie) then
  72.         if (Alistar.combo) then
  73.             zakursorem()
  74.         end
  75.     end
  76. end
  77.  
  78. function zakursorem()
  79.     if GetDistance(mousePos) > 10 then
  80.         local moveToPos = myHero + (Vector(mousePos) - myHero):normalized()*250
  81.         myHero:MoveTo(moveToPos.x, moveToPos.z)
  82.     end
  83. end
  84.  
  85.  
  86. function menu()
  87.     Alistar = scriptConfig("[NECEK CARRY] Alistar", "ali")
  88.     Misc = scriptConfig("[NECEK CARRY] Misc", "ali2")
  89.     Activator = scriptConfig("[NECEK CARRY] Activator", "ali3")
  90.    
  91.     -- ALISTAR ==================
  92.    
  93.     Alistar:addParam("otoczka", "Draw circle W", SCRIPT_PARAM_ONOFF, true)
  94.     Alistar:addParam("otoczkaq", "Draw circle Q", SCRIPT_PARAM_ONOFF, true)
  95.     Alistar:addParam("otoczkae", "Draw circle E", SCRIPT_PARAM_ONOFF, true)
  96.     Alistar:addParam("combo", "Combo", SCRIPT_PARAM_ONKEYDOWN, false, string.byte(32))
  97.     Alistar:addParam("info", "     == By necek123 ==", SCRIPT_PARAM_INFO, "")
  98.    
  99.     -- MISC =======================
  100.    
  101.     Misc:addParam("podazanie", "Follow the mouse", SCRIPT_PARAM_ONOFF, true)
  102.     Misc:addParam("info2", "", SCRIPT_PARAM_INFO, "")
  103.     Misc:addParam("autoeon", "Auto E", SCRIPT_PARAM_ONOFF, true)
  104.     Misc:addParam("autoe", "Auto E %", SCRIPT_PARAM_SLICE, 30, 0, 100, 0)
  105.     Misc:addParam("autoesojusznik", "Auto Heal Ally", SCRIPT_PARAM_ONOFF, true)
  106.     Misc:addParam("AllyPro", "Heal Ally % HP", SCRIPT_PARAM_SLICE, 50, 0, 100, 0)
  107.     Misc:addTS(ts)
  108.    
  109.    
  110.     -- ACTIVATOR ==================
  111.    
  112.     Activator:addParam("DFG", "Deathfire Grasp", SCRIPT_PARAM_ONOFF, true)
  113.    
  114.    
  115.     -- PERMA SHOW ====================
  116.    
  117.     Alistar:permaShow("info")
  118.     Alistar:permaShow("combo")
  119.     Misc:permaShow("autoeon")
  120.     Misc:permaShow("autoesojusznik")
  121. end
  122.  
  123.  
  124.  
  125. function dfg()
  126. if (Alistar.combo) then
  127.     if (Activator.DFG) then
  128.         if (DFG ~= nil) then
  129.             if (ts.target ~= nil) then
  130.                 if (GetDistance(ts.target) <= 750) then -- range dfg
  131.                     CastSpell(DFG, ts.target)
  132.                 end
  133.             end
  134.         end
  135.     end
  136. end
  137. end
  138.  
  139. -- AUTO HEAL =======================
  140.  
  141. function autoe()
  142.     if (Misc.autoe ~= 0 and Misc.autoeon) then
  143.         if myHero.health < (myHero.maxHealth * ( Misc.autoe / 100)) then
  144.             if (myHero:CanUseSpell(_E)) then
  145.                 CastSpell(_E)
  146.             end
  147.         end
  148.     end
  149. end
  150.  
  151. -- AUTO HEAL SOJUSZNIKOW (ALLY) ======================================
  152.  
  153. function autoesojusznicy()
  154.     for i, ally in ipairs(GetAllyHeroes()) do
  155.         if ally ~= nil and GetDistance(ally) < 575 and not ally.dead and ally.visible and myHero:CanUseSpell(_E) == READY and Misc.autoesojusznik and sprawdzhp(ally, Misc.AllyPro) then
  156.             CastSpell(_E)
  157.         end
  158.     end
  159. end
  160.  
  161. function sprawdzhp(unit, HealthValue)
  162.     if unit.health < (unit.maxHealth * (HealthValue/100))
  163.         then return true
  164.     else
  165.         return false
  166.     end
  167. end
  168.  
  169. -- =============================================
Advertisement
Add Comment
Please, Sign In to add comment