Full Code
if GetObjectName(GetMyHero()) ~= "Twitch" then return end
if not pcall( require, "Inspired" ) then PrintChat("You are missing Inspired.lua!") return end
PrintChat("Twitch loaded.")
PrintChat("by Law")
local mainMenu = Menu("Twitch", "Twitch")
mainMenu:Menu("Combo", "Combo")
mainMenu.Combo:Boolean("useW", "Use W in combo", true)
mainMenu.Combo:Boolean("useE", "E at max stacks", true)
mainMenu.Combo:Key("Combo1", "Combo", string.byte(" "))
------------------------------------------------------
mainMenu:Menu("Killsteal", "Killsteal")
mainMenu.Killsteal:Boolean("ksE", "Use E - KS", true)
mainMenu.Killsteal:Boolean("ksEp", "Poison + E - KS", true)
------------------------------------------------------
mainMenu:Menu("Items", "Items")
mainMenu.Items:Boolean("useCut", "Bilgewater Cutlass", true)
mainMenu.Items:Boolean("useBork", "Blade of the Ruined King", true)
mainMenu.Items:Boolean("useGhost", "Youmuu's Ghostblade", true)
mainMenu.Items:Boolean("useRedPot", "Elixir of Wrath", true)
------------------------------------------------------
mainMenu:Menu("Drawings", "Drawings")
mainMenu.Drawings:Boolean("drawPoison", "Draw Posion-Damage", true)
mainMenu.Drawings:Boolean("drawE", "Draw E-Damage", true)
mainMenu.Drawings:Boolean("drawR", "Draw R-Range", true)
mainMenu.Drawings:Slider("Quality","Circle Quality", 100 , 1, 255, 1)
------------------------------------------------------
mainMenu:Menu("Misc", "Misc")
mainMenu.Misc:Boolean("iR", "Invisible Recall", true)
mainMenu.Misc:Key("recall", "Recall Key", string.byte("T"))
PassiveStacks = {}
PassiveApply = {}
OnUpdateBuff(function(Object,buff)
if buff.Name == "twitchdeadlyvenom" and GetTeam(Object) ~= GetTeam(myHero) and GetObjectType(Object) == Obj_AI_Hero then
if PassiveStacks[GetNetworkID(Object)] == nil then
PassiveStacks[GetNetworkID(Object)] = 0
end
if PassiveStacks[GetNetworkID(Object)] and PassiveStacks[GetNetworkID(Object)] < 6 then
PassiveStacks[GetNetworkID(Object)] = PassiveStacks[GetNetworkID(Object)] + 1
end
PassiveApply[GetNetworkID(Object)] = buff.StartTime
-----------------------
if GetLevel(myHero) >= 1 and GetLevel(myHero) <= 4 then
pDMG = 12
elseif GetLevel(myHero) >= 5 and GetLevel(myHero) <= 8 then
pDMG = 18
elseif GetLevel(myHero) >= 9 and GetLevel(myHero) <= 12 then
pDMG = 24
elseif GetLevel(myHero) >= 13 and GetLevel(myHero) <= 16 then
pDMG = 30
elseif GetLevel(myHero) >= 17 and GetLevel(myHero) <= 18 then
pDMG = 36
end
-----------------------
end
end)
OnRemoveBuff(function(Object,buff)
if buff.Name == "twitchdeadlyvenom" and GetTeam(Object) ~= GetTeam(myHero) and GetObjectType(Object) == Obj_AI_Hero then
PassiveStacks[GetNetworkID(Object)] = 0
PassiveApply[GetNetworkID(Object)] = 0
end
end)
OnDraw(function(myHero)
local target = GetCurrentTarget()
-- DRAWINGS
if mainMenu.Drawings.drawPoison:Value() or mainMenu.Drawings.drawE:Value() then
if ValidTarget(target,2000) and eDMG ~= nil and truepoisonDMG ~= nil then
for i,enemy in pairs(GetEnemyHeroes()) do
if CanUseSpell(myHero,_E) == READY and mainMenu.Drawings.drawE:Value() and mainMenu.Drawings.drawPoison:Value() then
DrawDmgOverHpBar(enemy,GetCurrentHP(enemy),eDMG,0, 0xff00ff00)
DrawDmgOverHpBar(enemy,GetCurrentHP(enemy)-eDMG,truepoisonDMG,0,0xffff00ff)
elseif CanUseSpell(myHero,_E) == ONCOOLDOWN and mainMenu.Drawings.drawE:Value() and mainMenu.Drawings.drawPoison:Value() then
DrawDmgOverHpBar(enemy,GetCurrentHP(enemy),truepoi sonDMG,0,0xffff00ff)
end
if mainMenu.Drawings.drawE:Value() and not mainMenu.Drawings.drawPoison:Value() then
DrawDmgOverHpBar(enemy,GetCurrentHP(enemy),eDMG,0, 0xff00ff00)
end
if mainMenu.Drawings.drawPoison:Value() and not mainMenu.Drawings.drawE:Value() then
DrawDmgOverHpBar(enemy,GetCurrentHP(enemy),truepoi sonDMG,0,0xffff00ff)
end
end
end
end
-- Draw R
if mainMenu.Drawings.drawR:Value() and CanUseSpell(myHero,_R) == READY and ValidTarget(target,2000) then
DrawCircle(GetOrigin(myHero),900,0,mainMenu.Drawin gs.Quality:Value(),ARGB(100,33,139,6))
end
end)
OnTick(function(myHero)
local target = GetCurrentTarget()
local myHeroPos = GetOrigin(myHero)
-- Items
local CutBlade = GetItemSlot(myHero,3144)
local bork = GetItemSlot(myHero,3153)
local ghost = GetItemSlot(myHero,3142)
local redpot = GetItemSlot(myHero,2140)
-- Use Items
if mainMenu.Combo.Combo1:Value() then
if CutBlade >= 1 and ValidTarget(target,550+50) and mainMenu.Items.useCut:Value() then
if CanUseSpell(myHero,GetItemSlot(myHero,3144)) == READY then
CastTargetSpell(target, GetItemSlot(myHero,3144))
end
elseif bork >= 1 and ValidTarget(target,550+50) and (GetMaxHP(myHero) / GetCurrentHP(myHero)) >= 1.25 and mainMenu.Items.useBork:Value() then
if CanUseSpell(myHero,GetItemSlot(myHero,3153)) == READY then
CastTargetSpell(target,GetItemSlot(myHero,3153))
end
end
if ghost >= 1 and ValidTarget(target,GetRange(myHero)+50) and mainMenu.Items.useGhost:Value() then
if CanUseSpell(myHero,GetItemSlot(myHero,3142)) == READY then
CastSpell(GetItemSlot(myHero,3142))
end
end
if redpot >= 1 and ValidTarget(target,GetRange(myHero)+50) and mainMenu.Items.useRedPot:Value() then
if CanUseSpell(myHero,GetItemSlot(myHero,2140)) == READY then
CastSpell(GetItemSlot(myHero,2140))
end
end
end
-- Combo
if mainMenu.Combo.Combo1:Value() and ValidTarget(target, 1500) then
if mainMenu.Combo.useW:Value() and ValidTarget(target, 1500) and CanUseSpell(myHero,_W) == READY then
local WPred = GetPredictionForPlayer(myHeroPos,target,GetMoveSpe ed(target),1400,250,940,220,false,true)
if WPred.HitChance == 1 then
CastSkillShot(_W,WPred.PredPos.x,WPred.PredPos.y,W Pred.PredPos.z)
end
end
if mainMenu.Combo.useE:Value() and ValidTarget(target,1200) and CanUseSpell(myHero,_E) == READY and PassiveStacks[GetNetworkID(target)] == 6 then
CastSpell(_E)
end
end
if ValidTarget(GetCurrentTarget(), 2000) then
for i,enemy in pairs(GetEnemyHeroes()) do
if PassiveStacks[GetNetworkID(enemy)] ~= nil then
if CanUseSpell(myHero,_E) == READY then
eDMG = CalcDamage(myHero,enemy,(15*GetCastLevel(myHero,_E )+5+(5*GetCastLevel(myHero,_E)+10+(0.2*GetBonusAP( myHero)+0.25*GetBonusDmg(myHero)))*PassiveStacks[GetNetworkID(enemy)]),0)
else eDMG = 0 end
end
-- Posion-Damage
if PassiveApply[GetNetworkID(enemy)] ~= nil and pDMG ~= nil and PassiveStacks[GetNetworkID(enemy)] > 0 and PassiveApply[GetNetworkID(enemy)] > 0 then
local p = GetGameTimer() - PassiveApply[GetNetworkID(enemy)]
local pp = 6 - p
truepoisonDMG = (((pDMG/6) * PassiveStacks[GetNetworkID(enemy)]) * pp -(GetHPRegen(enemy)* pp ))
end
end
end
-- Killsteal E
if mainMenu.Killsteal.ksE:Value() and eDMG ~= nil then
for i,enemy in pairs(GetEnemyHeroes()) do
if CanUseSpell(myHero,_E) == READY and ValidTarget(enemy, 1200) and GetCurrentHP(enemy) + GetDmgShield(enemy) < eDMG and mainMenu.Killsteal.ksE:Value() then
CastSpell(_E)
end
if CanUseSpell(myHero,_E) == READY and ValidTarget(enemy, 1200) and truepoisonDMG ~= nil and GetCurrentHP(enemy) + GetDmgShield(enemy) < eDMG + truepoisonDMG and mainMenu.Killsteal.ksE:Value() and mainMenu.Killsteal.ksEp:Value() then
CastSpell(_E)
end
end
end
-- Recall
if mainMenu.Misc.iR:Value() then
if CanUseSpell(myHero,_Q) == READY then
if mainMenu.Misc.recall:Value() then
CastSpell(_Q)
DelayAction(function()
CastSpell(RECALL)
end, 10)
end
end
end
end)