sociophobia

Untitled

Jul 19th, 2015
201
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.73 KB | None | 0 0
  1. -- leeched from inspired cassiopea <3
  2. require('Inspired')
  3. require('IMenu')
  4. require('IWalk')
  5. AddButton("Activator", "Use Activator", true)
  6. function AfterObjectLoopEvent(myHero)
  7.         DrawMenu()
  8.         local potionslot = GetItemSlot(myHero,3157)
  9.         local potionslot2 = GetItemSlot(myHero,3153)
  10.         local potionslot3 = GetItemSlot(myHero,3144)
  11.         if((GetCurrentHP(myHero)/(GetMaxHP(myHero)/100))) < 26 and GetButtonValue("Activator")then
  12.                 if CanUseSpell(myHero,_W)== READY then
  13.                         local mPos = GetMyHeroPos()
  14.                         CastSkillShot(_W,mPos.x,mPos.y,mPos.z)
  15.                 else
  16.                 if GetItemSlot(myHero,3157) > 0 then
  17.                         CastTargetSpell(myHero,3157)
  18.                         end
  19.                 end
  20.         end
  21.         if KeyIsDown(0x20) then
  22.         local unit = GetTarget(1000)
  23.         if ValidTarget(unit, 1000) then
  24.                 if GetButtonValue("Activator") then
  25.             CastItems(unit)
  26.                         --if potionslot2 > 0 then
  27.                                 --CastTargetSpell(myHero,3153)
  28.                         --end
  29.                         --if potionslot3 > 0 then
  30.                                -- CastTargetSpell(myHero,3144)
  31.                         end
  32.                 end
  33.                 if CanUseSpell(myHero, _R) == READY and IsInDistance(unit, 700) then
  34.                         CastTargetSpell(unit, _R)
  35.                 elseif CanUseSpell(myHero, _Q) == READY and IsInDistance(unit, 600)  then
  36.                         CastTargetSpell(unit,_Q)
  37.                 elseif  CanUseSpell(myHero, _E) == READY and IsInDistance(unit, 350) then
  38.                         CastSkillShot(myHero,_E)
  39.                 end
  40.         end
  41.         IWalk()
  42.         end
  43. end
Advertisement
Add Comment
Please, Sign In to add comment