Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class 'Plugin'
- if myHero.charName ~= "Orianna" then return end
- local Target
- local Ball = myHero
- local BallMoving = false
- local LastQ = 0
- local Enemies = AutoCarry.Helper.EnemyTable
- function Plugin:__init()
- SkillQ = AutoCarry.Skills:NewSkill(false, _Q, 825, "OriannaQ", AutoCarry.SPELL_CIRCLE, 50, false, false, 1.2, 250, 80, false) -- "Borrowed" from Klokje's im Orianna :3
- AutoCarry.Crosshair:SetSkillCrosshairRange(900)
- AutoCarry.Plugins:RegisterBonusLastHitDamage(PassiveFarm)
- end
- function PassiveFarm(minion)
- return getDmg("P", minion, myHero)
- end
- function Plugin:OnTick()
- Target = AutoCarry.Crosshair:GetTarget()
- if not BallMoving then
- local CanW = (myHero:CanUseSpell(_W) == READY)
- if Menu.autoHarras then
- if Target ~= nil then
- if myHero.mana/myHero.maxMana*100 >= Menu.autoMinMana then
- SkillQ:Cast(Target)
- if Ball ~= nil and Ball ~= myHero and GetDistance(Ball, Target) < 250 and LastQ < GetTickCount() + 100 and CanW then CastSpell(_W) end
- end
- end
- end
- if Menu.comboHelper and AutoCarry.Keys.AutoCarry then
- if Target ~= nil then
- SkillQ:Cast(Target)
- if Ball ~= nil and GetDistance(Ball, Target) < 250 and LastQ < GetTickCount() + 100 and CanW then CastSpell(_W) end
- if Ball ~= nil and Ball ~= myHero then
- local CanHit = checkhitlinepass(Ball, myHero, 30, 1100, Target, GetDistance(Target, Target.minBBox)/2)
- local CanE = (myHero:CanUseSpell(_E) == READY)
- if CanHit and CanE then CastSpell(_E, myHero) end
- end
- end
- end
- if Menu.autoUlt then
- local ValidTargets = 0
- for i, Enemy in pairs(Enemies) do
- if Enemy ~= nil and not Enemy.dead and Enemy.visible and GetDistance(Ball, Enemy) < 400 then ValidTargets = ValidTargets + 1 end
- end
- if ValidTargets >= Menu.autoMinEnemies and myHero.mana >= 100 then CastSpell(_R) end
- end
- if Menu.KillUlt then
- local KillableTargets = 0
- for i, Enemy in pairs(Enemies) do
- if Enemy ~= nil and not Enemy.dead and Enemy.visible and GetDistance(Ball, Enemy) < 400 and getDmg("R", Enemy, myHero) >= Enemy.health then KillableTargets = KillableTargets + 1 end
- end
- if KillableTargets >= Menu.KillMinEnemies and myHero.mana >= 100 then CastSpell(_R) end
- end
- end
- end
- function Plugin:OnDraw()
- if Ball ~= nil and not Ball.isMe and Menu.drawReturnRange then DrawCircle(Ball.x, Ball.y, Ball.z, 1325, 0xFF80FF00) end
- end
- function Plugin:OnProcessSpell(unit, spell)
- if unit.isMe and spell.name == "OrianaRedactCommand" then
- Ball = spell.target
- BallMoving = false
- end
- if unit.isMe and spell.name == "OrianaIzunaCommand" then
- BallMoving = true
- LastQ = GetTickCount()
- end
- end
- function Plugin:OnCreateObj(obj)
- if obj == nil or obj.name == nil then return end
- if (obj.name:find("yomu_ring_green")) then
- Ball = obj
- BallMoving = false
- end
- if (obj.name:find("Orianna_Ball_Flash_Reverse")) then
- Ball = myHero
- BallMoving = false
- end
- end
- function Plugin:OnSendPacket(p)
- local packet = Packet(p)
- if packet:get('name') == 'S_CAST' then
- local SpellID = packet:get('spellId')
- if SpellID == SPELL_4 then
- local ValidTargets = 0
- for i, Enemy in pairs(Enemies) do
- if Enemy ~= nil and not Enemy.dead and Enemy.visible and GetDistance(Ball, Enemy) < 400 then ValidTargets = ValidTargets + 1 end
- end
- if ValidTargets == 0 then p:Block() end
- end
- end
- end
- Menu = AutoCarry.Plugins:RegisterPlugin(Plugin(), "aOrianna v1.0")
- Menu:addParam("Information1", " aOrianna v1.0 by Anonymous", SCRIPT_PARAM_INFO, "")
- Menu:addParam("Information2", "== Auto-Settings: ==", SCRIPT_PARAM_INFO, "")
- Menu:addParam("autoHarras","Automaticly Harras", SCRIPT_PARAM_ONOFF, true)
- Menu:addParam("autoMinMana","Minimum % mana", SCRIPT_PARAM_SLICE, 35, 0, 100, 0)
- Menu:addParam("autoUlt","Automaticly ultimate", SCRIPT_PARAM_ONOFF, true)
- Menu:addParam("autoMinEnemies","if can catch X enemies:", SCRIPT_PARAM_SLICE, 3, 1, 5, 0)
- Menu:addParam("KillUlt","Automaticly kill with ultimate", SCRIPT_PARAM_ONOFF, true)
- Menu:addParam("KillMinEnemies","if can kill X enemies:", SCRIPT_PARAM_SLICE, 3, 1, 5, 0)
- Menu:addParam("Information2", "== Helper-Settings: ==", SCRIPT_PARAM_INFO, "")
- Menu:addParam("comboHelper","Combo in AutoCarry mode", SCRIPT_PARAM_ONOFF, true)
- Menu:addParam("shieldInCombo","Use shield to damage enemy", SCRIPT_PARAM_ONOFF, true)
- Menu:addParam("drawReturnRange","Draw return range of ball", SCRIPT_PARAM_ONOFF, true)
Advertisement
Add Comment
Please, Sign In to add comment