Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --[[ Hecarim Helper 1.2.1b by HeX
- modded by xkjtx(added AAkite, useE, qSpam, and toggle ult)
- Ranges turn on when skill is ready and off when not ready(Correct ranges for circles in game)
- -- Spells will cast at a closer range so spells hit target everytime
- -- Also changed the combo a little to see if it helps some.. It helped me...
- ]]--
- if myHero.charName ~= "Hecarim" then return end
- --[[ Ranges ]]--
- local qRange = 345 -- lowered so Q hits everytime
- local wRange = 520 -- lowered so W hits everytime
- local rRange = 995 -- lowered so R hits everytime
- local rSpeed = 1.6
- --[[ For AA code ]]
- local lastBasicAttack = 0
- local startAttackSpeed = 0.625
- local swing = 0
- local nextTick = 0
- local waitDelay = 400
- --[[ Items ]]--
- local ignite, ghost = nil, nil
- local QREADY, WREADY, EREADY, RREADY = false, false, false, false
- local DFGREADY, BRKREADY, HXGREADY, BWCREADY, SRRREADY, YGBREADY = false, false, false, false, false, false
- local DFGSlot, BRKSlot, HXGSlot, BWCSlot, SRRSlot, YGBSlot = nil, nil, nil, nil, nil, nil
- function OnLoad()
- --PrintChat("<font color='#CCCCCC'> >> Hecarim Helper 1.2.1b loaded! <<</font>")
- HHConfig = scriptConfig("Hecarim Helper", "HecarimHelper")
- HHConfig:addParam("scriptActive", "Combo", SCRIPT_PARAM_ONKEYDOWN, false, 32) -- Space
- HHConfig:addParam("speedBurst", "Speed Burst", SCRIPT_PARAM_ONKEYDOWN, false, string.byte("S")) -- S
- HHConfig:addParam("qSpamm", "Spamms Q", SCRIPT_PARAM_ONKEYDOWN, false, string.byte("Q")) -- S
- HHConfig:addParam("AAkite", "Kiting", SCRIPT_PARAM_ONKEYDOWN, false, string.byte("G")) -- Z -- Toggle on and it will move to mouse, then try to AA the target over and over again
- HHConfig:addParam("useE", "Toggle Use E in Combo", SCRIPT_PARAM_ONKEYTOGGLE, true, string.byte("V")) -- V
- HHConfig:addParam("useR", "Toggle Use Ultimate in Combo", SCRIPT_PARAM_ONKEYTOGGLE, true, string.byte("X")) -- X
- HHConfig:addParam("autoignite", "Ignite when Killable", SCRIPT_PARAM_ONOFF, false) -- I have my own ignite
- HHConfig:addParam("drawcirclesSelf", "Draw Circles - Self", SCRIPT_PARAM_ONOFF, true)
- HHConfig:addParam("drawcirclesEnemy", "Draw Circles - Enemy", SCRIPT_PARAM_ONOFF, true)
- HHConfig:permaShow("scriptActive")
- HHConfig:permaShow("speedBurst")
- HHConfig:permaShow("qSpamm")
- HHConfig:permaShow("useE")
- HHConfig:permaShow("useR")
- HHConfig:permaShow("AAkite")
- ts = TargetSelector(TARGET_LOW_HP, rRange+105, DAMAGE_MAGIC, true) -- So you can select target
- ts.name = "Hecarim"
- HHConfig:addTS(ts)
- if myHero:GetSpellData(SUMMONER_1).name:find("SummonerDot") then ignite = SUMMONER_1
- elseif myHero:GetSpellData(SUMMONER_2).name:find("SummonerDot") then ignite = SUMMONER_2
- end
- if myHero:GetSpellData(SUMMONER_1).name:find("SummonerHaste") then ghost = SUMMONER_1
- elseif myHero:GetSpellData(SUMMONER_2).name:find("SummonerHaste") then ghost = SUMMONER_2
- end
- lastBasicAttack = os.clock()
- end
- function OnProcessSpell(unit, spell)
- if unit.isMe and (spell.name:find("Attack") ~= nil) then
- swing = 1
- lastBasicAttack = os.clock()
- end
- end
- function OnTick()
- ts:update()
- if myHero.dead then return end
- -- Auto Kite code starts here
- if ts.target ~= nil and HHConfig.AAkite and (not HHConfig.scriptActive or not HHConfig.qSpamm) then
- local AttackDelay = 1/(myHero.attackSpeed*startAttackSpeed)
- if swing == 1 and os.clock() > lastBasicAttack + AttackDelay then
- swing = 0
- end
- --[[ Auto Attacks ]]--
- local tick = GetTickCount()
- if swing == 0 then
- if GetDistance(ts.target) < rRange and GetTickCount() > nextTick then
- myHero:Attack(ts.target)
- nextTick = GetTickCount() + waitDelay
- if QREADY and GetDistance(ts.target) <= qRange then
- CastSpell(_Q)
- end
- end
- elseif swing == 1 and GetTickCount() > (nextTick + 100) then
- myHero:MoveTo(mousePos.x, mousePos.z)
- end
- end
- -- Auto Kite code ends here
- if ts.target ~= nil then
- travelDuration = (GetDistance(ts.target, myHero)/rSpeed)
- end
- if ts.target ~= nil and RREADY and travelDuration ~= nil then
- predic = GetPredictionPos(ts.target, travelDuration)
- end
- if predic ~= nil and ts.target ~= nil then
- TargetPos = Vector(predic.x, predic.y, predic.z)
- MyPos = Vector(myHero.x, myHero.y, myHero.z)
- UltPos = TargetPos + (TargetPos-MyPos)*((200/GetDistance(ts.target)))
- end
- DFGSlot, BRKSlot, HXGSlot, BWCSlot, SRRSlot, YGBSlot = GetInventorySlotItem(3153), GetInventorySlotItem(3128), GetInventorySlotItem(3146), GetInventorySlotItem(3144), GetInventorySlotItem(3069), GetInventorySlotItem(3142)
- DFGREADY = (DFGSlot ~= nil and myHero:CanUseSpell(DFGSlot) == READY)
- BRKREADY = (BRKSlot ~= nil and myHero:CanUseSpell(BRKSlot) == READY)
- HXGREADY = (HXGSlot ~= nil and myHero:CanUseSpell(HXGSlot) == READY)
- BWCREADY = (BWCSlot ~= nil and myHero:CanUseSpell(BWCSlot) == READY)
- SRRREADY = (SRRSlot ~= nil and myHero:CanUseSpell(SRRSlot) == READY)
- YGBREADY = (YGBSlot ~= nil and myHero:CanUseSpell(YGBSlot) == READY)
- IREADY = (ignite ~= nil and myHero:CanUseSpell(ignite) == READY)
- GREADY = (ghost ~= nil and myHero:CanUseSpell(ghost) == READY)
- QREADY = (myHero:CanUseSpell(_Q) == READY)
- WREADY = (myHero:CanUseSpell(_W) == READY)
- EREADY = (myHero:CanUseSpell(_E) == READY)
- RREADY = (myHero:CanUseSpell(_R) == READY)
- --[[ Auto Ignite ]]--
- if HHConfig.autoignite then
- if IREADY then
- local ignitedmg = 0
- for i = 1, heroManager.iCount, 1 do
- local enemyhero = heroManager:getHero(i)
- if ValidTarget(enemyhero,600) then
- ignitedmg = 50 + 20 * myHero.level
- if enemyhero.health <= ignitedmg then
- CastSpell(ignite, enemyhero)
- end
- end
- end
- end
- end
- --[[ Speed Burst ]]--
- if HHConfig.speedBurst then
- if SRRREADY then CastSpell(SRRSlot) end
- --if GREADY then CastSpell(ghost) end -- taken out because I like to use ghost on my own
- if EREADY then CastSpell(_E) end
- if YGBREADY then CastSpell(YGBSlot) end
- myHero:MoveTo(mousePos.x, mousePos.z)
- end
- --[[ Q-W Spamm ]]--
- if HHConfig.qSpamm and ts.target ~= nil then
- if QREADY and GetDistance(ts.target) <= qRange then
- CastSpell(_Q)
- elseif WREADY and myHero:CanUseSpell(_Q) == COOLDOWN and GetDistance(ts.target) <= wRange then
- CastSpell(_W)
- end
- if GetDistance(ts.target) <= wRange then
- myHero:Attack(ts.target)
- end
- end
- --[[ Basic Combo ]]--
- if HHConfig.scriptActive and ts.target ~= nil then
- --[[ Items ]]--
- if (GetDistance(ts.target) > 475 and GetDistance(ts.target) < 750) then
- if DFGREADY then CastSpell(DFGSlot, ts.target) end
- if BRKREADY then CastSpell(BRKSlot, ts.target) end
- if HXGREADY then CastSpell(HXGSlot, ts.target) end
- if BWCREADY then CastSpell(BWCSlot, ts.target) end
- if YGBREADY then CastSpell(YGBSlot) end
- end
- --[[ Abilities ]]--
- if QREADY and GetDistance(ts.target) <= qRange then
- CastSpell(_Q)
- end
- if GetDistance(ts.target) <= wRange then
- myHero:Attack(ts.target)
- end
- if WREADY and GetDistance(ts.target) <= wRange then
- CastSpell(_W)
- end
- if HHConfig.useR and RREADY and UltPos ~= nil and GetDistance(predic) < rRange then
- CastSpell(_R, UltPos.x, UltPos.z)
- end
- if HHConfig.useE and EREADY and GetDistance(ts.target) < wRange then
- CastSpell(_E, ts.target.x, ts.target.z)
- end
- end
- end
- function OnDraw()
- if HHConfig.drawcirclesSelf and not myHero.dead then
- if QREADY then
- DrawCircle(myHero.x, myHero.y, myHero.z, qRange+5, 0x00CCFF)
- end
- if WREADY then
- DrawCircle(myHero.x, myHero.y, myHero.z, wRange+5, 0x00FF00)
- end
- if RREADY then
- DrawCircle(myHero.x, myHero.y, myHero.z, rRange+5, 0x9900CC)
- end
- end
- if ts.target ~= nil and HHConfig.drawcirclesEnemy and not myHero.dead then
- for j=0, 10 do
- DrawCircle(ts.target.x, ts.target.y, ts.target.z, 40 + j*1.5, 0x00FF00)
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement