Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --[[
- Cassiopeia Combo 1.3b by eXtragoZ -- edited/modded by xkjtx
- -- Using prediction added by xkjtx
- -Full combo: Items -> Q -> W -> E (if poisoned or low life)(configurable)
- -Harass: Cast Q at target
- -Ult hot-key: When hot key pressed(and target in range) Cass with cast Ult at your mouse position
- -Supports Deathfire Grasp, Bilgewater Cutlass, Hextech Gunblade
- -Target configuration
- -Press shift to configure
- I recommend using it with AIOSkillshots
- ]]--
- if myHero.charName ~= "Cassiopeia" then return end
- --[[ Code ]]
- local TSrange = 900
- local erange = 700
- local qwrrange = 845 -- lowered to make sure Q hits
- -- Active
- local poisonedtimets = 0
- local poisonedtime = {}
- -- draw
- -- ts
- local ts
- local travelDuration, predic = nil, nil
- local delay = 300
- local speed = 1.975
- --
- local ignite = nil
- local DFGSlot, HXGSlot, BWCSlot, SheenSlot, TrinitySlot, LichBaneSlot = nil, nil, nil, nil, nil, nil
- local QREADY, WREADY, EREADY, RREADY, DFGREADY, HXGREADY, BWCREADY, IREADY = false, false, false, false, false, false, false, false
- function OnLoad()
- CCConfig = scriptConfig("Cassiopeia Combo 1.3", "cassiopeiacombo")
- CCConfig:addParam("scriptActive", "Active", SCRIPT_PARAM_ONKEYDOWN, false, 32)
- CCConfig:addParam("harassActive", "Harass", SCRIPT_PARAM_ONKEYDOWN, false, string.byte("S"))
- CCConfig:addParam("ultActive", "Ult at Mouse Pos", SCRIPT_PARAM_ONKEYDOWN, false, string.byte("R"))
- CCConfig:addParam("drawcircles", "Draw Circles", SCRIPT_PARAM_ONOFF, true)
- CCConfig:addParam("useonlowhp", "Use E on low hp", SCRIPT_PARAM_ONOFF, true)
- CCConfig:permaShow("scriptActive")
- CCConfig:permaShow("harassActive")
- CCConfig:permaShow("ultActive")
- ts = TargetSelector(TARGET_LOW_HP,TSrange,DAMAGE_MAGIC)
- ts.name = "Cassiopeia"
- CCConfig: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
- for i=1, heroManager.iCount do poisonedtime[i] = 0 end
- end
- function OnTick()
- ts:update()
- DFGSlot, HXGSlot, BWCSlot, SheenSlot, TrinitySlot, LichBaneSlot = GetInventorySlotItem(3128), GetInventorySlotItem(3146), GetInventorySlotItem(3144), GetInventorySlotItem(3057), GetInventorySlotItem(3078), GetInventorySlotItem(3100)
- QREADY = (myHero:CanUseSpell(_Q) == READY)
- WREADY = (myHero:CanUseSpell(_W) == READY)
- EREADY = (myHero:CanUseSpell(_E) == READY)
- RREADY = (myHero:CanUseSpell(_R) == READY)
- DFGREADY = (DFGSlot ~= nil and myHero:CanUseSpell(DFGSlot) == READY)
- HXGREADY = (HXGSlot ~= nil and myHero:CanUseSpell(HXGSlot) == READY)
- BWCREADY = (BWCSlot ~= nil and myHero:CanUseSpell(BWCSlot) == READY)
- IREADY = (ignite ~= nil and myHero:CanUseSpell(ignite) == READY)
- if ts.index ~= nil then poisonedtimets = poisonedtime[ts.index] end
- if ts.target ~= nil and not myHero.dead then
- travelDuration = (delay + GetDistance(myHero, ts.target)/speed)
- ts:SetPrediction(travelDuration)
- predic = ts.nextPosition
- if CCConfig.scriptActive then
- if predic ~= nil and QREADY and GetDistance(predic) <= qwrrange then
- CastSpell(_Q, predic.x, predic.z)
- end
- if predic ~= nil and EREADY and GetDistance(predic) <= qwrrange then
- CastSpell(_W, predic.x, predic.z)
- end
- --[[if GetDistance(ts.target) <= erange and EREADY then
- CastSpell(_E, ts.target)
- end]]
- if GetDistance(ts.target) <= erange then
- myHero:Attack(ts.target)
- end
- end
- if CCConfig.harassActive then
- if predic ~= nil and QREADY and GetDistance(predic) <= qwrrange then
- CastSpell(_Q, predic.x, predic.z)
- end
- end
- end
- --[[if CCConfig.harassActive and ts.target ~= nil then
- if QREADY then
- CastSpell(_Q, ts.target.x, ts.target.z)
- myHero:Attack(ts.target)
- end
- end]]
- if CCConfig.scriptActive and ts.target ~= nil then
- if DFGREADY then CastSpell(DFGSlot, ts.target) end
- if HXGREADY then CastSpell(HXGSlot, ts.target) end
- if BWCREADY then CastSpell(BWCSlot, ts.target) end
- --if QREADY then CastSpell(_Q, ts.target.x, ts.target.z) end
- --if WREADY then CastSpell(_W, ts.target.x, ts.target.z) end
- if EREADY and (GetTickCount()-poisonedtimets < 2600 or (getDmg("E", ts.target, myHero) >= ts.target.health and CCConfig.useonlowhp)) then
- CastSpell(_E, ts.target)
- end
- end
- if CCConfig.ultActive and ts.target ~= nil and GetDistance(ts.target)<=qwrrange then CastSpell(_R, 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 OnDraw()
- if CCConfig.drawcircles and not myHero.dead then
- DrawCircle(myHero.x, myHero.y, myHero.z, erange, 0x19A712)
- if ts.target ~= nil then
- for j=0, 15 do
- DrawCircle(ts.target.x, ts.target.y, ts.target.z, 40 + j*1.5, 0x00FF00)
- end
- end
- end
- end
- function OnSendChat(msg)
- ts:OnSendChat(msg, "pri")
- end
- PrintChat(" >> Cassiopeia Combo 1.3 loaded!")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement