Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- iCass made by Apple
- -- minor changes by burn
- if myHero.charName ~= "Cassiopeia" then return end
- --[[ Config ]]--
- local QDelay = 600
- local WDelay = 300
- local QRange = 850
- local ERange = 700
- local RRange = 850
- local BRKid, DFGid, EXECid, YOGHid, RANOid, BWCid, HXGid = 3153, 3128, 3123, 3142, 3143, 3144, 3146
- local BRKSlot, DFGSlot, EXECSlot, YOGHSlot, RANOSlot, BWCSlot, HXGSlot = nil, nil, nil, nil, nil, nil, nil
- --[[ Script Variables]]--
- local poisonedtimets = 0
- local poisonedtime = {}
- local ts = TargetSelector(TARGET_LOW_HP,QRange,DAMAGE_MAGIC, false)
- local abilitySequence = {1,3,2,1,1,4,1,3,1,2,4,3,2,3,2,4,3,2}
- function OnLoad()
- acConfig = scriptConfig("iCass", "iCass")
- acConfig:addParam("scriptActive","Combo", SCRIPT_PARAM_ONKEYDOWN, false, 32)
- acConfig:addParam("harass", "Poke!", SCRIPT_PARAM_ONKEYDOWN, false, 65) --A
- acConfig:addParam("CastUltimate", "Cast R", SCRIPT_PARAM_ONKEYDOWN, false, 82) --R
- acConfig:addParam("SpamE", "Spam E?", SCRIPT_PARAM_ONOFF, true)
- acConfig:addParam("KillE", "KS with E?", SCRIPT_PARAM_ONOFF, true)
- acConfig:addParam("drawcircles","Draw Our Range", SCRIPT_PARAM_ONOFF, true)
- acConfig:addParam("PMove","Move when Combo or Poke?", SCRIPT_PARAM_ONOFF, true)
- acConfig:addParam("autolvl","Auto level?", SCRIPT_PARAM_ONOFF, true)
- acConfig:permaShow("scriptActive")
- acConfig:permaShow("CastUltimate")
- acConfig:permaShow("SpamE")
- ts.name = "Cassiopeia"
- acConfig:addTS(ts)
- for i=1, heroManager.iCount do poisonedtime[i] = 0 end
- end
- function OnTick()
- ts:update()
- if acConfig.autolvl then
- if myHero:GetSpellData(_Q).level + myHero:GetSpellData(_W).level + myHero:GetSpellData(_E).level + myHero:GetSpellData(_R).level < myHero.level then
- local spellSlot = { SPELL_1, SPELL_2, SPELL_3, SPELL_4, }
- local level = { 0, 0, 0, 0 }
- for i = 1, myHero.level, 1 do
- level[abilitySequence[i]] = level[abilitySequence[i]] + 1
- end
- for i, v in ipairs({ myHero:GetSpellData(_Q).level, myHero:GetSpellData(_W).level, myHero:GetSpellData(_E).level, myHero:GetSpellData(_R).level }) do
- if v < level[i] then LevelSpell(spellSlot[i]) end
- end
- end
- end
- DFGSlot = GetInventorySlotItem(DFGid)
- EXECSlot = GetInventorySlotItem(EXECid)
- YOGHSlot = GetInventorySlotItem(YOGHid)
- RANOSlot = GetInventorySlotItem(RANOid)
- BWCSlot = GetInventorySlotItem(BWCid)
- HXGSlot = GetInventorySlotItem(HXGid)
- BRKSlot = GetInventorySlotItem(BRKid)
- if acConfig.CastUltimate and myHero:CanUseSpell(_R) == READY and ts.target ~= nil then
- CastSpell(_R, ts.target.x, ts.target.z)
- end
- if ValidTarget(ts.target) then poisonedtimets = poisonedtime[ts.index] end
- if acConfig.scriptActive or acConfig.harass then
- if ValidTarget(ts.target, QRange) then
- if myHero:CanUseSpell(_Q) == READY then
- local QPos = GetPredictionPos(ts.target, QDelay)
- if QPos ~= nil then
- CastSpell(_Q, QPos.x, QPos.z)
- end
- end
- if acConfig.scriptActive and myHero:CanUseSpell(_W) == READY then
- local WPos = GetPredictionPos(ts.target, WDelay)
- if WPos ~= nil then
- CastSpell(_W, WPos.x, WPos.z)
- end
- end
- end
- end
- if ValidTarget(ts.target, ERange) and myHero:CanUseSpell(_E) == READY then
- if acConfig.scriptActive or acConfig.SpamE or (getDmg("E", ts.target, myHero) > ts.target.health and acConfig.KillE) then
- if (GetTickCount()-poisonedtimets < 2600) then
- if acConfig.scriptActive then
- if iReady(DFGSlot) then CastSpell(DFGSlot, ts.target) end
- if iReady(EXECSlot) then CastSpell(EXECSlot, ts.target) end
- if iReady(YOGHSlot) then CastSpell(YOGHSlot) end
- if iReady(RANOSlot) then CastSpell(RANOSlot, ts.target) end
- if iReady(BWCSlot) then CastSpell(BWCSlot, ts.target) end
- if iReady(HXGSlot) and not acConfig.KillHXG then CastSpell(HXGSlot, ts.target) end
- if iReady(BRKSlot) then CastSpell(BRKSlot, ts.target) end
- end
- CastSpell(_E, ts.target)
- end
- end
- end
- if acConfig.PMove and ts.target ~= nil and (acConfig.scriptActive or acConfig.harass) then myHero:MoveTo(mousePos.x, mousePos.z) end
- end
- function OnCreateObj(obj)
- if obj.name:find("Global_Poison") then
- for i=1, heroManager.iCount do
- local enemy = heroManager:GetHero(i)
- if enemy.team ~= myHero.team and GetDistance(obj, enemy) < 80 then poisonedtime[i] = GetTickCount() end
- end
- end
- end
- function iReady(itemslot)
- if itemslot ~= nil and myHero:CanUseSpell(itemslot) then
- return true
- else
- return false
- end
- end
- function OnDraw()
- if not myHero.dead and acConfig.drawcircles then
- DrawCircle(myHero.x, myHero.y, myHero.z, QRange, 0x25de69)
- DrawCircle(myHero.x, myHero.y, myHero.z, ERange, 0xc2743c)
- if ValidTarget(ts.target) then
- DrawText("Targetting: " .. ts.target.charName, 15, 100, 100, 0xFFFF0000)
- DrawCircle(ts.target.x, ts.target.y, ts.target.z, 100, 0xFF80FF00)
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment