sociophobia

Untitled

Jul 19th, 2015
191
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. require('Inspired')
  2. require('IMenu')
  3. --require('MinionManager')
  4. require('IWalk')
  5. AddButton("Activator", "Use Activator", true)
  6. function AfterObjectLoopEvent(myHero)
  7.         DrawMenu()
  8.      i = {3157}
  9.         local potionslot = GetItemSlot(myHero,3157)
  10.         local potionslot2 = GetItemSlot(myHero,3153)
  11.         local potionslot3 = GetItemSlot(myHero,3144)
  12.         if((GetCurrentHP(myHero)/(GetMaxHP(myHero)/100))) < 26 and GetButtonValue("Activator")then
  13.                 if CanUseSpell(myHero,_W)== READY then
  14.                         local mPos = GetMyHeroPos()
  15.                         CastSkillShot(_W,mPos.x,mPos.y,mPos.z)
  16.                 else
  17.             slot = GetItemSlot(GetMyHero(),k)
  18.                 if slot and CanUseSpell(GetMyHero(), slot) == READY then
  19.                 CastTargetSpell(GetMyHero(), slot)
  20.                         end
  21.                 end
  22.         end
  23.         if KeyIsDown(0x20) then
  24.         local unit = GetTarget(1000)
  25.         if ValidTarget(unit, 1000) then
  26.                if GetButtonValue("Activator") then
  27.             CastItems(unit)
  28.                        -- if potionslot2 > 0 then
  29.                         --        CastTargetSpell(myHero,3153)
  30.                      --   end
  31.                     --    if potionslot3 > 0 then
  32.                      --           CastTargetSpell(myHero,3144)
  33.                    --     end
  34.                end
  35.                 if CanUseSpell(myHero, _R) == READY and IsInDistance(unit, 700) then
  36.                         CastTargetSpell(unit, _R)
  37.                 elseif CanUseSpell(myHero, _Q) == READY and IsInDistance(unit, 600)  then
  38.                         CastTargetSpell(unit,_Q)
  39.                 elseif  CanUseSpell(myHero, _E) == READY and IsInDistance(unit, 350) then
  40.                         CastSkillShot(myHero,_E)
  41.                 end
  42.         while(castitems(unit))
  43.             CastItems(unit)
  44.         end
  45.        
  46.         end
  47.     --EnemyMinions = GetMinions(2, 700, myHero)
  48.     --if KeyIsDown(0x47) then
  49.         --if CanUseSpell(myHero, _R) == READY and IsInDistance(EnemyMinions, 700) and GetDistance()>400 then
  50.                         --CastTargetSpell(EnemyMinions, _R)
  51.         --end
  52.     --end
  53.  
  54.         IWalk()
  55.         end
  56. end
  57.  
  58. --function GetDistance(p1,p2)
  59.    -- p1 = GetOrigin(p1) or p1
  60.    -- p2 = GetOrigin(p2) or p2
  61.     --return math.sqrt(GetDistanceSqr(p1,p2))
  62. --end
Advertisement
Add Comment
Please, Sign In to add comment