Advertisement
kam726

Untitled

Sep 20th, 2017
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.48 KB | None | 0 0
  1. local lastaa = 0
  2. local anim = 0
  3. local wind = 0
  4.  
  5. menu = MenuConfig("gso_twitch", "gso twitch")
  6. menu:KeyBinding("combo", "Combo", 32)
  7.  
  8. OnProcessSpellAttack(function(unit, aa)
  9. if unit == myHero then
  10. anim = aa.animationTime * 850
  11. wind = aa.windUpTime * 850
  12. lastaa = GetTickCount()
  13. end
  14. end)
  15.  
  16. OnTick(function()
  17. if menu.combo:Value() then
  18. local t = nil
  19. local num = 10000
  20. local r = myHero.range + myHero.boundingRadius
  21. for _, enemy in pairs(GetEnemyHeroes()) do
  22. if ValidTarget(enemy, r + enemy.boundingRadius) then
  23. local arm = enemy.armor
  24. local hp = enemy.health * (arm/(arm+100))
  25. if hp < num then
  26. num = hp
  27. t = enemy
  28. end
  29. end
  30. end
  31. if t ~= nil then
  32. if GetTickCount() > lastaa + anim then
  33. AttackUnit(t)
  34. elseif GetTickCount() > lastaa + wind then
  35. MoveToXYZ(GetMousePos())
  36. end
  37. elseif GetTickCount() > lastaa + wind then
  38. MoveToXYZ(GetMousePos())
  39. end
  40. end
  41. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement