Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- require('Inspired')
- require('IMenu')
- --require('MinionManager')
- require('IWalk')
- AddButton("Activator", "Use Activator", true)
- function AfterObjectLoopEvent(myHero)
- DrawMenu()
- i = {3157}
- local potionslot = GetItemSlot(myHero,3157)
- local potionslot2 = GetItemSlot(myHero,3153)
- local potionslot3 = GetItemSlot(myHero,3144)
- if((GetCurrentHP(myHero)/(GetMaxHP(myHero)/100))) < 26 and GetButtonValue("Activator")then
- if CanUseSpell(myHero,_W)== READY then
- local mPos = GetMyHeroPos()
- CastSkillShot(_W,mPos.x,mPos.y,mPos.z)
- else
- slot = GetItemSlot(GetMyHero(),k)
- if slot and CanUseSpell(GetMyHero(), slot) == READY then
- CastTargetSpell(GetMyHero(), slot)
- end
- end
- end
- if KeyIsDown(0x20) then
- local unit = GetTarget(1000)
- if ValidTarget(unit, 1000) then
- if GetButtonValue("Activator") then
- CastItems(unit)
- -- if potionslot2 > 0 then
- -- CastTargetSpell(myHero,3153)
- -- end
- -- if potionslot3 > 0 then
- -- CastTargetSpell(myHero,3144)
- -- end
- end
- if CanUseSpell(myHero, _R) == READY and IsInDistance(unit, 700) then
- CastTargetSpell(unit, _R)
- elseif CanUseSpell(myHero, _Q) == READY and IsInDistance(unit, 600) then
- CastTargetSpell(unit,_Q)
- elseif CanUseSpell(myHero, _E) == READY and IsInDistance(unit, 350) then
- CastSkillShot(myHero,_E)
- end
- while(castitems(unit))
- CastItems(unit)
- end
- end
- --EnemyMinions = GetMinions(2, 700, myHero)
- --if KeyIsDown(0x47) then
- --if CanUseSpell(myHero, _R) == READY and IsInDistance(EnemyMinions, 700) and GetDistance()>400 then
- --CastTargetSpell(EnemyMinions, _R)
- --end
- --end
- IWalk()
- end
- end
- --function GetDistance(p1,p2)
- -- p1 = GetOrigin(p1) or p1
- -- p2 = GetOrigin(p2) or p2
- --return math.sqrt(GetDistanceSqr(p1,p2))
- --end
Advertisement
Add Comment
Please, Sign In to add comment