Advertisement
Morness

SxOrbWalk

Aug 1st, 2014
374
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 74.15 KB | None | 0 0
  1. ----------------------
  2. -------- SxOrb -------
  3. ----------------------
  4. class "SxOrbRaw"
  5. function SxOrbRaw:__init()
  6. self:LoadTables()
  7. self.SxOrbSettings = { ["ForceSelector"] = false, ["TargetRange"] = myHero.range + hitboxes[myHero.charName], ["RangeChanged"] = false, ["LastHitRange"] = myHero.range + hitboxes[myHero.charName]}
  8. self.HotKeys = { ["AutoCarry"] = {}, ["MixedMode"] = {}, ["LaneClear"] = {}, ["LastHit"] = {}, }
  9.  
  10. _G.SxOrbMenu = {}
  11. _G.SxOrbMenu.WaitForInterruptSpell = false
  12. self.WaitForAA = false
  13. self.Attackenabled = true
  14. self.DeactivateLuluPassive = false
  15. self.LastAA = 0
  16. self.NextAA = 0
  17. self.LastAction = 0
  18. self.LastDrawTick = 0
  19. self.Minions = minionManager(MINION_ENEMY, 2000, myHero, MINION_SORT_HEALTH_ASC)
  20. self.JungleMinions = minionManager(MINION_JUNGLE, 2000, myHero, MINION_SORT_MAXHEALTH_DEC)
  21. self.OtherMinions = minionManager(MINION_OTHER, 2000, myHero, MINION_SORT_HEALTH_ASC)
  22. self.MinionAttacks = {}
  23. self.CastedMinionAttacks = {}
  24. self.BeforeAttackCallbacks = {}
  25. self.OnAttackCallbacks = {}
  26. self.AfterAttackCallbacks = {}
  27. self.SpellResetCallbacks = {}
  28. self.MinionTargetStore = {}
  29. self.KillAbleMinions = {}
  30. self.BaseWindUpTime = 3
  31. self.BaseAnimationTime = 0.65
  32. self.Version = 1.45
  33. self.Language = {}
  34. self:SxDownloadString('http://www.lolskill.net/game/'..GetRegion()..'/'..myHero.name, function(data) self:ParseLolSkill(data) end)
  35.  
  36. self:LoadExtraFarmSettings()
  37. self:GetText("LOAD_COMPLETE", self.Version)
  38. print(self:GetText("LOAD_COMPLETE", self.Version))
  39. self.LuaSocket = require("socket")
  40. self.AutoUpdate = {["Host"] = "raw.githubusercontent.com", ["VersionLink"] = "/Superx321/BoL/master/common/SxOrbWalk.Version", ["ScriptLink"] = "/Superx321/BoL/master/common/SxOrbWalk.lua"}
  41. AddTickCallback(function() self:CheckUpdate() end)
  42. AddTickCallback(function() if self.SxOrbMenu then self:OnTick() end end)
  43. AddTickCallback(function() if self.SxOrbMenu then self:ClearMinionTargetStore() end end)
  44. AddTickCallback(function() if self.SxOrbMenu then self:CheckWaitForBuff() end end)
  45. AddTickCallback(function() if self.SxOrbMenu then self:HotKeyCallback() end end)
  46. AddDrawCallback(function() if self.SxOrbMenu then self:OnDraw() end end)
  47. AddProcessSpellCallback(function(unit, spell) if self.SxOrbMenu then self:OnProcessSpell(unit, spell) end end)
  48. AddProcessSpellCallback(function(unit, spell) if self.SxOrbMenu then self:GetMinionTargets(unit, spell) end end)
  49. AddCreateObjCallback(function(obj) if self.SxOrbMenu then self:OnCreateObj(obj) end end)
  50. AddDeleteObjCallback(function(obj) if self.SxOrbMenu then self:OnDeleteObj(obj) end end)
  51. AddMsgCallback(function(msg, key) if self.SxOrbMenu then self:OnWndMsg(msg, key) end end)
  52. end
  53.  
  54. function SxOrbRaw:LoadTables()
  55. self.IsBasicAttack = {["frostarrow"] = true,["CaitlynHeadshotMissile"] = true,["QuinnWEnhanced"] = true,["TrundleQ"] = true,["XenZhaoThrust"] = true,["XenZhaoThrust2"] = true,["XenZhaoThrust3"] = true,["GarenSlash2"] = true,["RenektonExecute"] = true,["RenektonSuperExecute"] = true,["KennenMegaProc"] = true,}
  56. self.projectilespeeds = {["Velkoz"]= 2000,["TeemoMushroom"] = math.huge,["TestCubeRender"] = math.huge ,["Xerath"] = 2000.0000 ,["Kassadin"] = math.huge ,["Rengar"] = math.huge ,["Thresh"] = 1000.0000 ,["Ziggs"] = 1500.0000 ,["ZyraPassive"] = 1500.0000 ,["ZyraThornPlant"] = 1500.0000 ,["KogMaw"] = 1800.0000 ,["HeimerTBlue"] = 1599.3999 ,["EliseSpider"] = 500.0000 ,["Skarner"] = 500.0000 ,["ChaosNexus"] = 500.0000 ,["Katarina"] = 467.0000 ,["Riven"] = 347.79999 ,["SightWard"] = 347.79999 ,["HeimerTYellow"] = 1599.3999 ,["Ashe"] = 2000.0000 ,["VisionWard"] = 2000.0000 ,["TT_NGolem2"] = math.huge ,["ThreshLantern"] = math.huge ,["TT_Spiderboss"] = math.huge ,["OrderNexus"] = math.huge ,["Soraka"] = 1000.0000 ,["Jinx"] = 2750.0000 ,["TestCubeRenderwCollision"] = 2750.0000 ,["Red_Minion_Wizard"] = 650.0000 ,["JarvanIV"] = 20.0000 ,["Blue_Minion_Wizard"] = 650.0000 ,["TT_ChaosTurret2"] = 1200.0000 ,["TT_ChaosTurret3"] = 1200.0000 ,["TT_ChaosTurret1"] = 1200.0000 ,["ChaosTurretGiant"] = 1200.0000 ,["Dragon"] = 1200.0000 ,["LuluSnowman"] = 1200.0000 ,["Worm"] = 1200.0000 ,["ChaosTurretWorm"] = 1200.0000 ,["TT_ChaosInhibitor"] = 1200.0000 ,["ChaosTurretNormal"] = 1200.0000 ,["AncientGolem"] = 500.0000 ,["ZyraGraspingPlant"] = 500.0000 ,["HA_AP_OrderTurret3"] = 1200.0000 ,["HA_AP_OrderTurret2"] = 1200.0000 ,["Tryndamere"] = 347.79999 ,["OrderTurretNormal2"] = 1200.0000 ,["Singed"] = 700.0000 ,["OrderInhibitor"] = 700.0000 ,["Diana"] = 347.79999 ,["HA_FB_HealthRelic"] = 347.79999 ,["TT_OrderInhibitor"] = 347.79999 ,["GreatWraith"] = 750.0000 ,["Yasuo"] = 347.79999 ,["OrderTurretDragon"] = 1200.0000 ,["OrderTurretNormal"] = 1200.0000 ,["LizardElder"] = 500.0000 ,["HA_AP_ChaosTurret"] = 1200.0000 ,["Ahri"] = 1750.0000 ,["Lulu"] = 1450.0000 ,["ChaosInhibitor"] = 1450.0000 ,["HA_AP_ChaosTurret3"] = 1200.0000 ,["HA_AP_ChaosTurret2"] = 1200.0000 ,["ChaosTurretWorm2"] = 1200.0000 ,["TT_OrderTurret1"] = 1200.0000 ,["TT_OrderTurret2"] = 1200.0000 ,["TT_OrderTurret3"] = 1200.0000 ,["LuluFaerie"] = 1200.0000 ,["HA_AP_OrderTurret"] = 1200.0000 ,["OrderTurretAngel"] = 1200.0000 ,["YellowTrinketUpgrade"] = 1200.0000 ,["MasterYi"] = math.huge ,["Lissandra"] = 2000.0000 ,["ARAMOrderTurretNexus"] = 1200.0000 ,["Draven"] = 1700.0000 ,["FiddleSticks"] = 1750.0000 ,["SmallGolem"] = math.huge ,["ARAMOrderTurretFront"] = 1200.0000 ,["ChaosTurretTutorial"] = 1200.0000 ,["NasusUlt"] = 1200.0000 ,["Maokai"] = math.huge ,["Wraith"] = 750.0000 ,["Wolf"] = math.huge ,["Sivir"] = 1750.0000 ,["Corki"] = 2000.0000 ,["Janna"] = 1200.0000 ,["Nasus"] = math.huge ,["Golem"] = math.huge ,["ARAMChaosTurretFront"] = 1200.0000 ,["ARAMOrderTurretInhib"] = 1200.0000 ,["LeeSin"] = math.huge ,["HA_AP_ChaosTurretTutorial"] = 1200.0000 ,["GiantWolf"] = math.huge ,["HA_AP_OrderTurretTutorial"] = 1200.0000 ,["YoungLizard"] = 750.0000 ,["Jax"] = 400.0000 ,["LesserWraith"] = math.huge ,["Blitzcrank"] = math.huge ,["ARAMChaosTurretInhib"] = 1200.0000 ,["Shen"] = 400.0000 ,["Nocturne"] = math.huge ,["Sona"] = 1500.0000 ,["ARAMChaosTurretNexus"] = 1200.0000 ,["YellowTrinket"] = 1200.0000 ,["OrderTurretTutorial"] = 1200.0000 ,["Caitlyn"] = 2500.0000 ,["Trundle"] = 347.79999 ,["Malphite"] = 1000.0000 ,["Mordekaiser"] = math.huge ,["ZyraSeed"] = math.huge ,["Vi"] = 1000.0000 ,["Tutorial_Red_Minion_Wizard"] = 650.0000 ,["Renekton"] = math.huge ,["Anivia"] = 1400.0000 ,["Fizz"] = math.huge ,["Heimerdinger"] = 1500.0000 ,["Evelynn"] = 467.0000 ,["Rumble"] = 347.79999 ,["Leblanc"] = 1700.0000 ,["Darius"] = math.huge ,["OlafAxe"] = math.huge ,["Viktor"] = 2300.0000 ,["XinZhao"] = 20.0000 ,["Orianna"] = 1450.0000 ,["Vladimir"] = 1400.0000 ,["Nidalee"] = 1750.0000 ,["Tutorial_Red_Minion_Basic"] = math.huge ,["ZedShadow"] = 467.0000 ,["Syndra"] = 1800.0000 ,["Zac"] = 1000.0000 ,["Olaf"] = 347.79999 ,["Veigar"] = 1100.0000 ,["Twitch"] = 2500.0000 ,["Alistar"] = math.huge ,["Akali"] = 467.0000 ,["Urgot"] = 1300.0000 ,["Leona"] = 347.79999 ,["Talon"] = math.huge ,["Karma"] = 1500.0000 ,["Jayce"] = 347.79999 ,["Galio"] = 1000.0000 ,["Shaco"] = math.huge ,["Taric"] = math.huge ,["TwistedFate"] = 1500.0000 ,["Varus"] = 2000.0000 ,["Garen"] = 347.79999 ,["Swain"] = 1600.0000 ,["Vayne"] = 2000.0000 ,["Fiora"] = 467.0000 ,["Quinn"] = 2000.0000 ,["Kayle"] = math.huge ,["Blue_Minion_Basic"] = math.huge ,["Brand"] = 2000.0000 ,["Teemo"] = 1300.0000 ,["Amumu"] = 500.0000 ,["Annie"] = 1200.0000 ,["Odin_Blue_Minion_caster"] = 1200.0000 ,["Elise"] = 1600.0000 ,["Nami"] = 1500.0000 ,["Poppy"] = 500.0000 ,["AniviaEgg"] = 500.0000 ,["Tristana"] = 2250.0000 ,["Graves"] = 3000.0000 ,["Morgana"] = 1600.0000 ,["Gragas"] = math.huge ,["MissFortune"] = 2000.0000 ,["Warwick"] = math.huge ,["Cassiopeia"] = 1200.0000 ,["Tutorial_Blue_Minion_Wizard"] = 650.0000 ,["DrMundo"] = math.huge ,["Volibear"] = 467.0000 ,["Irelia"] = 467.0000 ,["Odin_Red_Minion_Caster"] = 650.0000 ,["Lucian"] = 2800.0000 ,["Yorick"] = math.huge ,["RammusPB"] = math.huge ,["Red_Minion_Basic"] = math.huge ,["Udyr"] = 467.0000 ,["MonkeyKing"] = 20.0000 ,["Tutorial_Blue_Minion_Basic"] = math.huge ,["Kennen"] = 1600.0000 ,["Nunu"] = 500.0000 ,["Ryze"] = 2400.0000 ,["Zed"] = 467.0000 ,["Nautilus"] = 1000.0000 ,["Gangplank"] = 1000.0000 ,["Lux"] = 1600.0000 ,["Sejuani"] = 500.0000 ,["Ezreal"] = 2000.0000 ,["OdinNeutralGuardian"] = 1800.0000 ,["Khazix"] = 500.0000 ,["Sion"] = math.huge ,["Aatrox"] = 347.79999 ,["Hecarim"] = 500.0000 ,["Pantheon"] = 20.0000 ,["Shyvana"] = 467.0000 ,["Zyra"] = 1700.0000 ,["Karthus"] = 1200.0000 ,["Rammus"] = math.huge ,["Zilean"] = 1200.0000 ,["Chogath"] = 500.0000 ,["Malzahar"] = 2000.0000 ,["YorickRavenousGhoul"] = 347.79999 ,["YorickSpectralGhoul"] = 347.79999 ,["JinxMine"] = 347.79999 ,["YorickDecayedGhoul"] = 347.79999 ,["XerathArcaneBarrageLauncher"] = 347.79999 ,["Odin_SOG_Order_Crystal"] = 347.79999 ,["TestCube"] = 347.79999 ,["ShyvanaDragon"] = math.huge ,["FizzBait"] = math.huge ,["Blue_Minion_MechMelee"] = math.huge ,["OdinQuestBuff"] = math.huge ,["TT_Buffplat_L"] = math.huge ,["TT_Buffplat_R"] = math.huge ,["KogMawDead"] = math.huge ,["TempMovableChar"] = math.huge ,["Lizard"] = 500.0000 ,["GolemOdin"] = math.huge ,["OdinOpeningBarrier"] = math.huge ,["TT_ChaosTurret4"] = 500.0000 ,["TT_Flytrap_A"] = 500.0000 ,["TT_NWolf"] = math.huge ,["OdinShieldRelic"] = math.huge ,["LuluSquill"] = math.huge ,["redDragon"] = math.huge ,["MonkeyKingClone"] = math.huge ,["Odin_skeleton"] = math.huge ,["OdinChaosTurretShrine"] = 500.0000 ,["Cassiopeia_Death"] = 500.0000 ,["OdinCenterRelic"] = 500.0000 ,["OdinRedSuperminion"] = math.huge ,["JarvanIVWall"] = math.huge ,["ARAMOrderNexus"] = math.huge ,["Red_Minion_MechCannon"] = 1200.0000 ,["OdinBlueSuperminion"] = math.huge ,["SyndraOrbs"] = math.huge ,["LuluKitty"] = math.huge ,["SwainNoBird"] = math.huge ,["LuluLadybug"] = math.huge ,["CaitlynTrap"] = math.huge ,["TT_Shroom_A"] = math.huge ,["ARAMChaosTurretShrine"] = 500.0000 ,["Odin_Windmill_Propellers"] = 500.0000 ,["TT_NWolf2"] = math.huge ,["OdinMinionGraveyardPortal"] = math.huge ,["SwainBeam"] = math.huge ,["Summoner_Rider_Order"] = math.huge ,["TT_Relic"] = math.huge ,["odin_lifts_crystal"] = math.huge ,["OdinOrderTurretShrine"] = 500.0000 ,["SpellBook1"] = 500.0000 ,["Blue_Minion_MechCannon"] = 1200.0000 ,["TT_ChaosInhibitor_D"] = 1200.0000 ,["Odin_SoG_Chaos"] = 1200.0000 ,["TrundleWall"] = 1200.0000 ,["HA_AP_HealthRelic"] = 1200.0000 ,["OrderTurretShrine"] = 500.0000 ,["OriannaBall"] = 500.0000 ,["ChaosTurretShrine"] = 500.0000 ,["LuluCupcake"] = 500.0000 ,["HA_AP_ChaosTurretShrine"] = 500.0000 ,["TT_NWraith2"] = 750.0000 ,["TT_Tree_A"] = 750.0000 ,["SummonerBeacon"] = 750.0000 ,["Odin_Drill"] = 750.0000 ,["TT_NGolem"] = math.huge ,["AramSpeedShrine"] = math.huge ,["OriannaNoBall"] = math.huge ,["Odin_Minecart"] = math.huge ,["Summoner_Rider_Chaos"] = math.huge ,["OdinSpeedShrine"] = math.huge ,["TT_SpeedShrine"] = math.huge ,["odin_lifts_buckets"] = math.huge ,["OdinRockSaw"] = math.huge ,["OdinMinionSpawnPortal"] = math.huge ,["SyndraSphere"] = math.huge ,["Red_Minion_MechMelee"] = math.huge ,["SwainRaven"] = math.huge ,["crystal_platform"] = math.huge ,["MaokaiSproutling"] = math.huge ,["Urf"] = math.huge ,["TestCubeRender10Vision"] = math.huge ,["MalzaharVoidling"] = 500.0000 ,["GhostWard"] = 500.0000 ,["MonkeyKingFlying"] = 500.0000 ,["LuluPig"] = 500.0000 ,["AniviaIceBlock"] = 500.0000 ,["TT_OrderInhibitor_D"] = 500.0000 ,["Odin_SoG_Order"] = 500.0000 ,["RammusDBC"] = 500.0000 ,["FizzShark"] = 500.0000 ,["LuluDragon"] = 500.0000 ,["OdinTestCubeRender"] = 500.0000 ,["TT_Tree1"] = 500.0000 ,["ARAMOrderTurretShrine"] = 500.0000 ,["Odin_Windmill_Gears"] = 500.0000 ,["ARAMChaosNexus"] = 500.0000 ,["TT_NWraith"] = 750.0000 ,["TT_OrderTurret4"] = 500.0000 ,["Odin_SOG_Chaos_Crystal"] = 500.0000 ,["OdinQuestIndicator"] = 500.0000 ,["JarvanIVStandard"] = 500.0000 ,["TT_DummyPusher"] = 500.0000 ,["OdinClaw"] = 500.0000 ,["EliseSpiderling"] = 2000.0000 ,["QuinnValor"] = math.huge ,["UdyrTigerUlt"] = math.huge ,["UdyrTurtleUlt"] = math.huge ,["UdyrUlt"] = math.huge ,["UdyrPhoenixUlt"] = math.huge ,["ShacoBox"] = 1500.0000 ,["HA_AP_Poro"] = 1500.0000 ,["AnnieTibbers"] = math.huge ,["UdyrPhoenix"] = math.huge ,["UdyrTurtle"] = math.huge ,["UdyrTiger"] = math.huge ,["HA_AP_OrderShrineTurret"] = 500.0000 ,["HA_AP_Chains_Long"] = 500.0000 ,["HA_AP_BridgeLaneStatue"] = 500.0000 ,["HA_AP_ChaosTurretRubble"] = 500.0000 ,["HA_AP_PoroSpawner"] = 500.0000 ,["HA_AP_Cutaway"] = 500.0000 ,["HA_AP_Chains"] = 500.0000 ,["ChaosInhibitor_D"] = 500.0000 ,["ZacRebirthBloblet"] = 500.0000 ,["OrderInhibitor_D"] = 500.0000 ,["Nidalee_Spear"] = 500.0000 ,["Nidalee_Cougar"] = 500.0000 ,["TT_Buffplat_Chain"] = 500.0000 ,["WriggleLantern"] = 500.0000 ,["TwistedLizardElder"] = 500.0000 ,["RabidWolf"] = math.huge ,["HeimerTGreen"] = 1599.3999 ,["HeimerTRed"] = 1599.3999 ,["ViktorFF"] = 1599.3999 ,["TwistedGolem"] = math.huge ,["TwistedSmallWolf"] = math.huge ,["TwistedGiantWolf"] = math.huge ,["TwistedTinyWraith"] = 750.0000 ,["TwistedBlueWraith"] = 750.0000 ,["TwistedYoungLizard"] = 750.0000 ,["Red_Minion_Melee"] = math.huge ,["Blue_Minion_Melee"] = math.huge ,["Blue_Minion_Healer"] = 1000.0000 ,["Ghast"] = 750.0000 ,["blueDragon"] = 800.0000 ,["Red_Minion_MechRange"] = 3000.0000,}
  57. self.ResetSpells = {["PowerFist"]=true,["DariusNoxianTacticsONH"] = true,["Takedown"] = true,["Ricochet"] = true,["BlindingDart"] = false,["VayneTumble"] = true,["JaxEmpowerTwo"] = true,["MordekaiserMaceOfSpades"] = true,["SiphoningStrikeNew"] = true,["RengarQ"] = true,["YorickSpectral"] = true,["ViE"] = true,["GarenSlash3"] = true,["HecarimRamp"] = true,["XenZhaoComboTarget"] = true,["LeonaShieldOfDaybreak"] = true,["TalonNoxianDiplomacy"] = true,["TrundleTrollSmash"] = true,["VolibearQ"] = true,["PoppyDevastatingBlow"] = true,["LucianQ"] = true,["SivirW"] = true,["DetonatingShot"] = false, ["RivenTriCleave"] = true}
  58. hitboxes = {['RecItemsCLASSIC'] = 65, ['TeemoMushroom'] = 50.0, ['TestCubeRender'] = 65, ['Xerath'] = 65, ['Kassadin'] = 65, ['Rengar'] = 65, ['Thresh'] = 55.0, ['RecItemsTUTORIAL'] = 65, ['Ziggs'] = 55.0, ['ZyraPassive'] = 20.0, ['ZyraThornPlant'] = 20.0, ['KogMaw'] = 65, ['HeimerTBlue'] = 35.0, ['EliseSpider'] = 65, ['Skarner'] = 80.0, ['ChaosNexus'] = 65, ['Katarina'] = 65, ['Riven'] = 65, ['SightWard'] = 1, ['HeimerTYellow'] = 35.0, ['Ashe'] = 65, ['VisionWard'] = 1, ['TT_NGolem2'] = 80.0, ['ThreshLantern'] = 65, ['RecItemsCLASSICMap10'] = 65, ['RecItemsODIN'] = 65, ['TT_Spiderboss'] = 200.0, ['RecItemsARAM'] = 65, ['OrderNexus'] = 65, ['Soraka'] = 65, ['Jinx'] = 65, ['TestCubeRenderwCollision'] = 65, ['Red_Minion_Wizard'] = 48.0, ['JarvanIV'] = 65, ['Blue_Minion_Wizard'] = 48.0, ['TT_ChaosTurret2'] = 88.4, ['TT_ChaosTurret3'] = 88.4, ['TT_ChaosTurret1'] = 88.4, ['ChaosTurretGiant'] = 88.4, ['Dragon'] = 100.0, ['LuluSnowman'] = 50.0, ['Worm'] = 100.0, ['ChaosTurretWorm'] = 88.4, ['TT_ChaosInhibitor'] = 65, ['ChaosTurretNormal'] = 88.4, ['AncientGolem'] = 100.0, ['ZyraGraspingPlant'] = 20.0, ['HA_AP_OrderTurret3'] = 88.4, ['HA_AP_OrderTurret2'] = 88.4, ['Tryndamere'] = 65, ['OrderTurretNormal2'] = 88.4, ['Singed'] = 65, ['OrderInhibitor'] = 65, ['Diana'] = 65, ['HA_FB_HealthRelic'] = 65, ['TT_OrderInhibitor'] = 65, ['GreatWraith'] = 80.0, ['Yasuo'] = 65, ['OrderTurretDragon'] = 88.4, ['OrderTurretNormal'] = 88.4, ['LizardElder'] = 65.0, ['HA_AP_ChaosTurret'] = 88.4, ['Ahri'] = 65, ['Lulu'] = 65, ['ChaosInhibitor'] = 65, ['HA_AP_ChaosTurret3'] = 88.4, ['HA_AP_ChaosTurret2'] = 88.4, ['ChaosTurretWorm2'] = 88.4, ['TT_OrderTurret1'] = 88.4, ['TT_OrderTurret2'] = 88.4, ['TT_OrderTurret3'] = 88.4, ['LuluFaerie'] = 65, ['HA_AP_OrderTurret'] = 88.4, ['OrderTurretAngel'] = 88.4, ['YellowTrinketUpgrade'] = 1, ['MasterYi'] = 65, ['Lissandra'] = 65, ['ARAMOrderTurretNexus'] = 88.4, ['Draven'] = 65, ['FiddleSticks'] = 65, ['SmallGolem'] = 80.0, ['ARAMOrderTurretFront'] = 88.4, ['ChaosTurretTutorial'] = 88.4, ['NasusUlt'] = 80.0, ['Maokai'] = 80.0, ['Wraith'] = 50.0, ['Wolf'] = 50.0, ['Sivir'] = 65, ['Corki'] = 65, ['Janna'] = 65, ['Nasus'] = 80.0, ['Golem'] = 80.0, ['ARAMChaosTurretFront'] = 88.4, ['ARAMOrderTurretInhib'] = 88.4, ['LeeSin'] = 65, ['HA_AP_ChaosTurretTutorial'] = 88.4, ['GiantWolf'] = 65.0, ['HA_AP_OrderTurretTutorial'] = 88.4, ['YoungLizard'] = 50.0, ['Jax'] = 65, ['LesserWraith'] = 50.0, ['Blitzcrank'] = 80.0, ['brush_D_SR'] = 65, ['brush_E_SR'] = 65, ['brush_F_SR'] = 65, ['brush_C_SR'] = 65, ['brush_A_SR'] = 65, ['brush_B_SR'] = 65, ['ARAMChaosTurretInhib'] = 88.4, ['Shen'] = 65, ['Nocturne'] = 65, ['Sona'] = 65, ['ARAMChaosTurretNexus'] = 88.4, ['YellowTrinket'] = 1, ['OrderTurretTutorial'] = 88.4, ['Caitlyn'] = 65, ['Trundle'] = 65, ['Malphite'] = 80.0, ['Mordekaiser'] = 80.0, ['ZyraSeed'] = 65, ['Vi'] = 50, ['Tutorial_Red_Minion_Wizard'] = 48.0, ['Renekton'] = 80.0, ['Anivia'] = 65, ['Fizz'] = 65, ['Heimerdinger'] = 55.0, ['Evelynn'] = 65, ['Rumble'] = 80.0, ['Leblanc'] = 65, ['Darius'] = 80.0, ['OlafAxe'] = 50.0, ['Viktor'] = 65, ['XinZhao'] = 65, ['Orianna'] = 65, ['Vladimir'] = 65, ['Nidalee'] = 65, ['Tutorial_Red_Minion_Basic'] = 48.0, ['ZedShadow'] = 65, ['Syndra'] = 65, ['Zac'] = 80.0, ['Olaf'] = 65, ['Veigar'] = 55.0, ['Twitch'] = 65, ['Alistar'] = 80.0, ['Akali'] = 65, ['Urgot'] = 80.0, ['Leona'] = 65, ['Talon'] = 65, ['Karma'] = 65, ['Jayce'] = 65, ['Galio'] = 80.0, ['Shaco'] = 65, ['Taric'] = 65, ['TwistedFate'] = 65, ['Varus'] = 65, ['Garen'] = 65, ['Swain'] = 65, ['Vayne'] = 65, ['Fiora'] = 65, ['Quinn'] = 65, ['Kayle'] = 65, ['Blue_Minion_Basic'] = 48.0, ['Brand'] = 65, ['Teemo'] = 55.0, ['Amumu'] = 55.0, ['Annie'] = 55.0, ['Odin_Blue_Minion_caster'] = 48.0, ['Elise'] = 65, ['Nami'] = 65, ['Poppy'] = 55.0, ['AniviaEgg'] = 65, ['Tristana'] = 55.0, ['Graves'] = 65, ['Morgana'] = 65, ['Gragas'] = 80.0, ['MissFortune'] = 65, ['Warwick'] = 65, ['Cassiopeia'] = 65, ['Tutorial_Blue_Minion_Wizard'] = 48.0, ['DrMundo'] = 80.0, ['Volibear'] = 80.0, ['Irelia'] = 65, ['Odin_Red_Minion_Caster'] = 48.0, ['Lucian'] = 65, ['Yorick'] = 80.0, ['RammusPB'] = 65, ['Red_Minion_Basic'] = 48.0, ['Udyr'] = 65, ['MonkeyKing'] = 65, ['Tutorial_Blue_Minion_Basic'] = 48.0, ['Kennen'] = 55.0, ['Nunu'] = 65, ['Ryze'] = 65, ['Zed'] = 65, ['Nautilus'] = 80.0, ['Gangplank'] = 65, ['shopevo'] = 65, ['Lux'] = 65, ['Sejuani'] = 80.0, ['Ezreal'] = 65, ['OdinNeutralGuardian'] = 65, ['Khazix'] = 65, ['Sion'] = 80.0, ['Aatrox'] = 65, ['Hecarim'] = 80.0, ['Pantheon'] = 65, ['Shyvana'] = 50.0, ['Zyra'] = 65, ['Karthus'] = 65, ['Rammus'] = 65, ['Zilean'] = 65, ['Chogath'] = 80.0, ['Malzahar'] = 65, ['YorickRavenousGhoul'] = 1.0, ['YorickSpectralGhoul'] = 1.0, ['JinxMine'] = 65, ['YorickDecayedGhoul'] = 1.0, ['XerathArcaneBarrageLauncher'] = 65, ['Odin_SOG_Order_Crystal'] = 65, ['TestCube'] = 65, ['ShyvanaDragon'] = 80.0, ['FizzBait'] = 65, ['ShopKeeper'] = 65, ['Blue_Minion_MechMelee'] = 65.0, ['OdinQuestBuff'] = 65, ['TT_Buffplat_L'] = 65, ['TT_Buffplat_R'] = 65, ['KogMawDead'] = 65, ['TempMovableChar'] = 48.0, ['Lizard'] = 50.0, ['GolemOdin'] = 80.0, ['OdinOpeningBarrier'] = 65, ['TT_ChaosTurret4'] = 88.4, ['TT_Flytrap_A'] = 65, ['TT_Chains_Order_Periph'] = 65, ['TT_NWolf'] = 65.0, ['ShopMale'] = 65, ['OdinShieldRelic'] = 65, ['TT_Chains_Xaos_Base'] = 65, ['LuluSquill'] = 50.0, ['TT_Shopkeeper'] = 65, ['redDragon'] = 100.0, ['MonkeyKingClone'] = 65, ['Odin_skeleton'] = 65, ['OdinChaosTurretShrine'] = 88.4, ['Cassiopeia_Death'] = 65, ['OdinCenterRelic'] = 48.0, ['Ezreal_cyber_1'] = 65, ['Ezreal_cyber_3'] = 65, ['Ezreal_cyber_2'] = 65, ['OdinRedSuperminion'] = 55.0, ['TT_Speedshrine_Gears'] = 65, ['JarvanIVWall'] = 65, ['DestroyedNexus'] = 65, ['ARAMOrderNexus'] = 65, ['Red_Minion_MechCannon'] = 65.0, ['OdinBlueSuperminion'] = 55.0, ['SyndraOrbs'] = 65, ['LuluKitty'] = 50.0, ['SwainNoBird'] = 65, ['LuluLadybug'] = 50.0, ['CaitlynTrap'] = 65, ['TT_Shroom_A'] = 65, ['ARAMChaosTurretShrine'] = 88.4, ['Odin_Windmill_Propellers'] = 65, ['DestroyedInhibitor'] = 65, ['TT_NWolf2'] = 50.0, ['OdinMinionGraveyardPortal'] = 1.0, ['SwainBeam'] = 65, ['Summoner_Rider_Order'] = 65.0, ['TT_Relic'] = 65, ['odin_lifts_crystal'] = 65, ['OdinOrderTurretShrine'] = 88.4, ['SpellBook1'] = 65, ['Blue_Minion_MechCannon'] = 65.0, ['TT_ChaosInhibitor_D'] = 65, ['Odin_SoG_Chaos'] = 65, ['TrundleWall'] = 65, ['HA_AP_HealthRelic'] = 65, ['OrderTurretShrine'] = 88.4, ['OriannaBall'] = 48.0, ['ChaosTurretShrine'] = 88.4, ['LuluCupcake'] = 50.0, ['HA_AP_ChaosTurretShrine'] = 88.4, ['TT_Chains_Bot_Lane'] = 65, ['TT_NWraith2'] = 50.0, ['TT_Tree_A'] = 65, ['SummonerBeacon'] = 65, ['Odin_Drill'] = 65, ['TT_NGolem'] = 80.0, ['Shop'] = 65, ['AramSpeedShrine'] = 65, ['DestroyedTower'] = 65, ['OriannaNoBall'] = 65, ['Odin_Minecart'] = 65, ['Summoner_Rider_Chaos'] = 65.0, ['OdinSpeedShrine'] = 65, ['TT_Brazier'] = 65, ['TT_SpeedShrine'] = 65, ['odin_lifts_buckets'] = 65, ['OdinRockSaw'] = 65, ['OdinMinionSpawnPortal'] = 1.0, ['SyndraSphere'] = 48.0, ['TT_Nexus_Gears'] = 65, ['Red_Minion_MechMelee'] = 65.0, ['SwainRaven'] = 65, ['crystal_platform'] = 65, ['MaokaiSproutling'] = 48.0, ['Urf'] = 65, ['TestCubeRender10Vision'] = 65, ['MalzaharVoidling'] = 10.0, ['GhostWard'] = 1, ['MonkeyKingFlying'] = 65, ['LuluPig'] = 50.0, ['AniviaIceBlock'] = 65, ['TT_OrderInhibitor_D'] = 65, ['yonkey'] = 65, ['Odin_SoG_Order'] = 65, ['RammusDBC'] = 65, ['FizzShark'] = 65, ['LuluDragon'] = 50.0, ['OdinTestCubeRender'] = 65, ['OdinCrane'] = 65, ['TT_Tree1'] = 65, ['ARAMOrderTurretShrine'] = 88.4, ['TT_Chains_Order_Base'] = 65, ['Odin_Windmill_Gears'] = 65, ['ARAMChaosNexus'] = 65, ['TT_NWraith'] = 50.0, ['TT_OrderTurret4'] = 88.4, ['Odin_SOG_Chaos_Crystal'] = 65, ['TT_SpiderLayer_Web'] = 65, ['OdinQuestIndicator'] = 1.0, ['JarvanIVStandard'] = 65, ['TT_DummyPusher'] = 65, ['OdinClaw'] = 65, ['EliseSpiderling'] = 1.0, ['QuinnValor'] = 65, ['UdyrTigerUlt'] = 65, ['UdyrTurtleUlt'] = 65, ['UdyrUlt'] = 65, ['UdyrPhoenixUlt'] = 65, ['ShacoBox'] = 10, ['HA_AP_Poro'] = 65, ['AnnieTibbers'] = 80.0, ['UdyrPhoenix'] = 65, ['UdyrTurtle'] = 65, ['UdyrTiger'] = 65, ['HA_AP_OrderShrineTurret'] = 88.4, ['HA_AP_OrderTurretRubble'] = 65, ['HA_AP_Chains_Long'] = 65, ['HA_AP_OrderCloth'] = 65, ['HA_AP_PeriphBridge'] = 65, ['HA_AP_BridgeLaneStatue'] = 65, ['HA_AP_ChaosTurretRubble'] = 88.4, ['HA_AP_BannerMidBridge'] = 65, ['HA_AP_PoroSpawner'] = 50.0, ['HA_AP_Cutaway'] = 65, ['HA_AP_Chains'] = 65, ['HA_AP_ShpSouth'] = 65, ['HA_AP_HeroTower'] = 65, ['HA_AP_ShpNorth'] = 65, ['ChaosInhibitor_D'] = 65, ['ZacRebirthBloblet'] = 65, ['OrderInhibitor_D'] = 65, ['Nidalee_Spear'] = 65, ['Nidalee_Cougar'] = 65, ['TT_Buffplat_Chain'] = 65, ['WriggleLantern'] = 1, ['TwistedLizardElder'] = 65.0, ['RabidWolf'] = 65.0, ['HeimerTGreen'] = 50.0, ['HeimerTRed'] = 50.0, ['ViktorFF'] = 65, ['TwistedGolem'] = 80.0, ['TwistedSmallWolf'] = 50.0, ['TwistedGiantWolf'] = 65.0, ['TwistedTinyWraith'] = 50.0, ['TwistedBlueWraith'] = 50.0, ['TwistedYoungLizard'] = 50.0, ['Red_Minion_Melee'] = 48.0, ['Blue_Minion_Melee'] = 48.0, ['Blue_Minion_Healer'] = 48.0, ['Ghast'] = 60.0, ['blueDragon'] = 100.0, ['Red_Minion_MechRange'] = 65.0, ['Test_CubeSphere'] = 65,}
  59. self.SpellData = {
  60. ["Akali"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 600, Speed = 1000, Delay = 0.65, Width = 0} },
  61. ["Anivia"] = { [_E]= {Type = "Targeted", Collision = false, Range = 650, Speed = 1200, Delay = 0.5, Width = 0} },
  62. ["Annie"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 625, Speed = 1400, Delay = 0.5, Width = 0} },
  63. ["Brand"] = { [_Q]= {Type = "Linear", Collision = true, Range = 1150, Speed = 1200, Delay = 0.5, Width = 80} },
  64. ["Brand"] = { [_E]= {Type = "Linear", Collision = false, Range = 900, Speed = 1800, Delay = 0.5, Width = 0} },
  65. ["Cassiopeia"] = { [_E]= {Type = "Linear", Collision = false, Range = 700, Speed = 1900, Delay = 0.5, Width = 0} },
  66. ["Corki"] = { [_R]= {Type = "Linear", Collision = true, Range = 1250, Speed = 825, Delay = 0.5, Width = 45} },
  67. ["Mundo"] = { [_Q]= {Type = "Linear", Collision = true, Range = 1000, Speed = 1500, Delay = 0.5, Width = 75} },
  68. ["Elise"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 625, Speed = 2200, Delay = 0.5, Width = 0} },
  69. ["Ezreal"] = { [_Q]= {Type = "Linear", Collision = true, Range = 1000, Speed = 2000, Delay = 0.25, Width = 70 } },
  70. ["Fizz"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 550, Speed = math.huge, Delay = 0.25, Width = 0 } },
  71. ["Gankplank"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 625, Speed = 2000, Delay = 0.25, Width = 0 } },
  72. ["Graves"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 1100, Speed = 900, Delay = 0.25, Width = 10 } },
  73. ["Irelia"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 650, Speed = 2200, Delay = 0, Width = 0 } },
  74. ["Janna"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 600, Speed = 1600, Delay = 0.5, Width = 0 } },
  75. ["JarvanIV"] = { [_Q]= {Type = "Linear", Collision = false, Range = 600, Speed = 1600, Delay = 0.5, Width = 0 } },
  76. ["JarvanIV"] = { [_E]= {Type = "Targeted", Collision = false, Range = 830, Speed = math.huge, Delay = 0.5, Width = 70 } },
  77. ["Jax"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 700, Speed = math.huge, Delay = 0.5, Width = 0 } },
  78. ["Jinx"] = { [_W]= {Type = "Linear", Collision = true, Range = 1400, Speed = 1200, Delay = 0.5, Width = 70 } },
  79. ["Karthus"] = { [_Q]= {Type = "Circle", Collision = false, Range = 870, Speed = math.huge, Delay = 0.5, Width = 150 } },
  80. ["Kassadin"] = { [_Q]= {Type = "Circle", Collision = false, Range = 650, Speed = 1400, Delay = 0.5, Width = 0 } },
  81. ["Katarina"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 675, Speed = 1800, Delay = 0.5, Width = 0 } },
  82. ["Kayle"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 650, Speed = 1500, Delay = 0.5, Width = 0 } },
  83. ["Kennen"] = { [_Q]= {Type = "Linear", Collision = true, Range = 990, Speed = 1700, Delay = 0.5, Width = 50 } },
  84. ["Khazix"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 325, Speed = math.huge, Delay = 0.5, Width = 0 } },
  85. ["KogMaw"] = { [_Q]= {Type = "Linear", Collision = true, Range = 625, Speed = math.huge, Delay = 0.5, Width = 0 } },
  86. ["Leblanc"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 700, Speed = 2000, Delay = 0.5, Width = 0 } },
  87. ["LeeSin"] = { [_Q]= {Type = "Linear", Collision = false, Range = 1000, Speed = 1700, Delay = 0.5, Width = 0 } },
  88. ["Leona"] = { [_E]= {Type = "Linear", Collision = false, Range = 1050, Speed = 2000, Delay = 0.5, Width = 100 } },
  89. ["Lucian"] = { [_Q]= {Type = "Linear", Collision = false, Range = 530, Speed = math.huge, Delay = 0.5, Width = 50 } },
  90. ["Malphite"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 625, Speed = 1200, Delay = 0.5, Width = 0 } },
  91. ["MissFortune"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 650, Speed = 1400, Delay = 0.5, Width = 0 } },
  92. ["Nidalee"] = { [_Q]= {Type = "Linear", Collision = true, Range = 1400, Speed = 1300, Delay = 0.5, Width = 50 } },
  93. ["Nunu"] = { [_E]= {Type = "Targeted", Collision = true, Range = 550, Speed = 1000, Delay = 0.5, Width = 0 } },
  94. ["Olaf"] = { [_Q]= {Type = "Linear", Collision = false, Range = 950, Speed = 1600, Delay = 0.5, Width = 80 } },
  95. ["Olaf"] = { [_E]= {Type = "Targeted", Collision = false, Range = 325, Speed = math.huge, Delay = 0.5, Width = 0 } },
  96. ["Pantheon"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 600, Speed = 1500, Delay = 0.5, Width = 0 } },
  97. ["Rengar"] = { [_E]= {Type = "Targeted", Collision = false, Range = 1000, Speed = 1500, Delay = 0.5, Width = 50 } },
  98. ["Rumble"] = { [_E]= {Type = "Linear", Collision = true, Range = 850, Speed = 1200, Delay = 0.5, Width = 50 } },
  99. ["Ryze"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 625, Speed = 1400, Delay = 0.5, Width = 0 } },
  100. ["Ryze"] = { [_W]= {Type = "Targeted", Collision = false, Range = 600, Speed = math.huge, Delay = 0.5, Width = 0 } },
  101. ["Ryze"] = { [_E]= {Type = "Targeted", Collision = false, Range = 600, Speed = 1000, Delay = 0.5, Width = 0 } },
  102. ["Shaco"] = { [_E]= {Type = "Targeted", Collision = false, Range = 625, Speed = 1400, Delay = 0.5, Width = 0 } },
  103. ["Shen"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 475, Speed = 1500, Delay = 0.5, Width = 0 } },
  104. ["Singed"] = { [_E]= {Type = "Targeted", Collision = false, Range = 125, Speed = math.huge, Delay = 0.5, Width = 0 } },
  105. ["Sion"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 550, Speed = 1600, Delay = 0.5, Width = 0 } },
  106. ["Soraka"] = { [_E]= {Type = "Targeted", Collision = false, Range = 725, Speed = math.huge, Delay = 0.5, Width = 0 } },
  107. ["Teemo"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 580, Speed = 1500, Delay = 0.5, Width = 0 } },
  108. ["Urgot"] = { [_Q]= {Type = "Linear", Collision = true, Range = 1000, Speed = 1600, Delay = 0.5, Width = 80 } },
  109. ["Vayne"] = { [_E]= {Type = "Targeted", Collision = false, Range = 450, Speed = 1200, Delay = 0.5, Width = 0 } },
  110. ["Veigar"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 650, Speed = 1500, Delay = 0.5, Width = 0 } },
  111. ["Viktor"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 600, Speed = 1400, Delay = 0.5, Width = 0 } },
  112. ["Vladimir"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 600, Speed = 1400, Delay = 0.5, Width = 0 } },
  113. ["Warwick"] = { [_Q]= {Type = "Targeted", Collision = false, Range = 400, Speed = math.huge, Delay = 0.5, Width = 0 } },
  114. ["Yorick"] = { [_W]= {Type = "Circle", Collision = false, Range = 600, Speed = math.huge, Delay = 0.5, Width = 200 } },
  115. ["Yorick"] = { [_E]= {Type = "Targeted", Collision = false, Range = 550, Speed = math.huge, Delay = 0.5, Width = 200 } },
  116. }
  117.  
  118. self.DontInterruptSpells = {
  119. ["Nunu"] = {["Spell"] = "AbsoluteZero", ["Buff"] = "AbsoluteZero"},
  120. ["Katarina"] = {["Spell"] = "KatarinaR", ["Buff"] = "katarinarsound"},
  121. ["FiddleSticks"] = {["Spell"] = "Drain", ["Object"] = "Drain.troy"},
  122. ["MissFortune"] = {["Spell"] = "MissFortuneBulletTime", ["Object"] = "MissFortune_Base_R_mis.troy"},
  123. ["Malzahar"] = {["Spell"] = "AlZaharNetherGrasp", ["Object"] = "AlzaharNetherGrasp_beam.troy"},
  124. }
  125.  
  126. end
  127.  
  128. function SxOrbRaw:GetText(TextName, TextArg1, TextArg2)
  129. TextArg1 = (TextArg1 or "")
  130. TextArg2 = (TextArg2 or "")
  131. self.Language["MENU_NAME"] = "SxOrbWalker"
  132. self.Language["LOAD_COMPLETE"] = "<font color=\"#F0Ff8d\"><b>SxOrbWalk:</b></font> <font color=\"#FF0F0F\">Version "..TextArg1.." loaded</font>"
  133. self.Language["GENERAL_SETTINGS"] = "General Settings"
  134. self.Language["ENABLED"] = "Enabled"
  135. self.Language["IDLE"] = "Idle when Mouse is above Champ"
  136. self.Language["IDLE2"] = "Show Idle-Range Cirlce"
  137. self.Language["IDLE3"] = "Idle-Circle-Range"
  138. self.Language["VIPSELECTOR"] = "Use VIP Selector"
  139. self.Language["FARM_SETTINGS"] = "Farm Settings"
  140. self.Language["FARMDELAY"] = "Farm Delay"
  141. self.Language["WINDUPTIME"] = "Extra WindUp Time"
  142. self.Language["FARMOVERHARASS"] = "Focus LastHit over Harass"
  143. self.Language["SPELLFARM"] = "Use Spells to secure LastHits"
  144. self.Language["MASTERY_SETTINGS"] = "Mastery Settings"
  145. self.Language["BUTCHER"] = "Mastery: Butcher"
  146. self.Language["HAVOC"] = "Mastery: Havoc"
  147. self.Language["ARCANEBLADE"] = "Mastery: Arcane Blade"
  148. self.Language["HOTKEY_SETTINGS"] = "Hotkey Settings"
  149. self.Language["AUTOCARRY"] = "AutoCarry"
  150. self.Language["MIXEDMODE"] = "MixedMode"
  151. self.Language["LANECLEAR"] = "LaneClear"
  152. self.Language["LASTHIT"] = "LastHit"
  153. self.Language["DRAW_SETTINGS"] = "Draw Settings"
  154. self.Language["AARANGE"] = "Draw AA Range"
  155. self.Language["MINIONHPBAR"] = "Draw LastHit-Line on Minions"
  156. self.Language["MINIONCIRCLE"] = "Draw LastHit-Circle"
  157. self.Language["TARGETPRIORITY_SETTINGS"] = "TargetPriority Settings"
  158. self.Language["TARGETPRIORITY_INFOTEXT_1"] = "Higher Number = Higher Focus"
  159. self.Language["TARGETPRIORITY_INFOTEXT_2"] = "Means:"
  160. self.Language["TARGETPRIORITY_INFOTEXT_3"] = "EnemyAdc = 5"
  161. self.Language["TARGETPRIORITY_INFOTEXT_4"] = "EnemyTank = 1"
  162.  
  163. return self.Language[TextName]
  164. end
  165.  
  166. function SxOrbRaw:SxDownloadString(source, callback, working, OldLenght)
  167. if not working then
  168. if FileExist(LIB_PATH.."SxDownloadString") then os.remove(LIB_PATH.."SxDownloadString") end
  169. os.executePowerShellAsync([[$webClient = New-Object System.Net.WebClient;$webClient.DownloadFile(']]..source..[[', ']]..LIB_PATH.."SxDownloadString"..[[');exit;]])
  170. DelayAction(function() self:SxDownloadString(source, callback, true, 0) end)
  171. else
  172. if FileExist(LIB_PATH.."SxDownloadString") then
  173. FileOpen = io.open(LIB_PATH.."SxDownloadString", "r")
  174. FileString = FileOpen:read("*a")
  175. FileOpen:close()
  176. if #FileString > 0 and #FileString == OldLenght then
  177. os.remove(LIB_PATH.."SxDownloadString")
  178. callback(FileString)
  179. else
  180. DelayAction(function() self:SxDownloadString(source, callback, true, #FileString) end, 0.2)
  181. end
  182. else
  183. DelayAction(function() self:SxDownloadString(source, callback, true, 0) end)
  184. end
  185. end
  186. end
  187.  
  188. function SxOrbRaw:ParseLolSkill(data)
  189. SummonerInfo = {}
  190. for i=1,10 do
  191. FindSummonerStart = string.find(data, '<div class="summonername">')
  192. if FindSummonerStart then
  193. SummonerStartCut = string.sub(data,FindSummonerStart+2)
  194. NextSummoner = string.find(SummonerStartCut, '<div class="summonername">')
  195. if NextSummoner then
  196. SummonerSub = string.sub(SummonerStartCut, 0, NextSummoner)
  197. data = string.sub(data,NextSummoner-10)
  198. else
  199. SummonerSub = SummonerStartCut
  200. end
  201. NameStart = string.find(SummonerSub, '<a href=\"summoner/')
  202. NameEnd = string.find(SummonerSub, '</a></div>\n')
  203. NameRaw = string.sub(SummonerSub, NameStart, NameEnd-1)
  204. _,SummonerName = string.match(NameRaw, '(\">)(.*)')
  205. SummonerInfo[SummonerName] = {}
  206. SummonerInfo[SummonerName]["Masteries"] = {}
  207. for _,Points in string.gmatch(SummonerSub, '(<div class="rank">)(%d)(/)(%d)(</div>)') do
  208. table.insert(SummonerInfo[SummonerName]["Masteries"], Points)
  209. end
  210. _,League = string.match(SummonerSub, '(is currently ranked <b>)(.*)(</b> in Solo)')
  211. _,LP = string.match(SummonerSub, '( in SoloQueue and has <b>)(%d+)(</b> League Points)')
  212. _,SkillScore = string.match(SummonerSub, '( has performed <b>)(.*)(</b> with )')
  213. _,Games = string.match(SummonerSub, '( has played <b>)(.*)(</b> games with )')
  214. _,Performance = string.match(SummonerSub, '( has played <b>)(.*)(</b> than the average player with )')
  215. SummonerInfo[SummonerName]["League"] = League or "Unknown"
  216. SummonerInfo[SummonerName]["LP"] = LP or 0
  217. SummonerInfo[SummonerName]["SkillScore"] = SkillScore or 0
  218. SummonerInfo[SummonerName]["Games"] = Games or 0
  219. SummonerInfo[SummonerName]["Performance"] = Performance or "Unknown"
  220. if string.find(SummonerSub, '; queued up <b>alone</b>') then
  221. SummonerInfo[SummonerName]["Premade"] = "0"
  222. else
  223. _,PremadeTeam = string.match(SummonerSub, '(is <b>premade</b> as Premade Team )(%d)')
  224. SummonerInfo[SummonerName]["Premade"] = PremadeTeam
  225. end
  226. else
  227. break
  228. end
  229. end
  230. self.GotMasteries = true
  231. self.GotButcher = SummonerInfo[myHero.name]["Masteries"][4]
  232. self.GotHavoc = SummonerInfo[myHero.name]["Masteries"][20]
  233. self.GotBlade = SummonerInfo[myHero.name]["Masteries"][19]
  234. if self.SxOrbMenu and self.SxOrbMenu.masterysettings then
  235. self.SxOrbMenu.masterysettings.Butcher = self.GotButcher == "1"
  236. self.SxOrbMenu.masterysettings.Havoc = self.GotHavoc == "1"
  237. self.SxOrbMenu.masterysettings.ArcaneBlade = self.GotBlade == "1"
  238. end
  239. end
  240.  
  241. function SxOrbRaw:CheckUpdate()
  242. if not self.AutoUpdate["VersionSocket"] then
  243. self.AutoUpdate["VersionSocket"] = self.LuaSocket.connect("sx-bol.de", 80)
  244. self.AutoUpdate["VersionSocket"]:send("GET /BoL/TCPUpdater/GetScript.php?script="..self.AutoUpdate["Host"]..self.AutoUpdate["VersionLink"].."&rand="..tostring(math.random(1000)).." HTTP/1.0\r\n\r\n")
  245. end
  246.  
  247. if not self.AutoUpdate["ServerVersion"] and self.AutoUpdate["VersionSocket"] then
  248. self.AutoUpdate["VersionSocket"]:settimeout(0, 'b')
  249. self.AutoUpdate["VersionSocket"]:settimeout(99999999, 't')
  250. self.AutoUpdate["VersionReceive"], self.AutoUpdate["VersionStatus"] = self.AutoUpdate["VersionSocket"]:receive('*a')
  251. end
  252.  
  253. if not self.AutoUpdate["ServerVersion"] and self.AutoUpdate["VersionSocket"] and self.AutoUpdate["VersionStatus"] ~= 'timeout' and self.AutoUpdate["VersionReceive"] ~= nil then
  254. self.AutoUpdate["ServerVersion"] = tonumber(string.sub(self.AutoUpdate["VersionReceive"], string.find(self.AutoUpdate["VersionReceive"], "<bols".."cript>")+11, string.find(self.AutoUpdate["VersionReceive"], "</bols".."cript>")-1))
  255. end
  256.  
  257. if self.AutoUpdate["ServerVersion"] and type(self.AutoUpdate["ServerVersion"]) == "number" and self.AutoUpdate["ServerVersion"] > self.Version and not self.AutoUpdate["Finished"] then
  258. self.AutoUpdate["ScriptSocket"] = self.LuaSocket.connect("sx-bol.de", 80)
  259. self.AutoUpdate["ScriptSocket"]:send("GET /BoL/TCPUpdater/GetScript.php?script="..self.AutoUpdate["Host"]..self.AutoUpdate["ScriptLink"].."&rand="..tostring(math.random(1000)).." HTTP/1.0\r\n\r\n")
  260. self.AutoUpdate["ScriptReceive"], self.AutoUpdate["ScriptStatus"] = self.AutoUpdate["ScriptSocket"]:receive('*a')
  261. self.AutoUpdate["ScriptRAW"] = string.sub(self.AutoUpdate["ScriptReceive"], string.find(self.AutoUpdate["ScriptReceive"], "<bols".."cript>")+11, string.find(self.AutoUpdate["ScriptReceive"], "</bols".."cript>")-1)
  262. ScriptFileOpen = io.open(LIB_PATH.."SxOrbWalk.lua", "w+")
  263. ScriptFileOpen:write(self.AutoUpdate["ScriptRAW"])
  264. ScriptFileOpen:close()
  265. self.AutoUpdate["Finished"] = true
  266. print("<font color=\"#F0Ff8d\"><b>SxOrbWalk:</b></font> <font color=\"#FF0F0F\">New Version("..self.AutoUpdate["ServerVersion"]..") downloaded, load it with F9!</font>")
  267. end
  268. end
  269.  
  270. function SxOrbRaw:LoadToMenu(MainMenu, NoMenuKeys)
  271. if MainMenu then
  272. self.SxOrbMenu = MainMenu
  273. else
  274. self.SxOrbMenu = scriptConfig(self:GetText("MENU_NAME"), "SxOrb")
  275. end
  276. _G.SxOrbMenu = self.SxOrbMenu
  277. self.SxOrbMenu:addSubMenu(self:GetText("GENERAL_SETTINGS"), "generalsettings")
  278. self.SxOrbMenu.generalsettings:addParam("Enabled", self:GetText("ENABLED"), SCRIPT_PARAM_ONOFF, true)
  279. self.SxOrbMenu.generalsettings:addParam("StopMove", self:GetText("IDLE"), SCRIPT_PARAM_ONOFF, false)
  280. self.SxOrbMenu.generalsettings:addParam("StopMoveCircle", self:GetText("IDLE2"), SCRIPT_PARAM_ONOFF, false)
  281. self.SxOrbMenu.generalsettings:addParam("StopMoveSlider", self:GetText("IDLE3"), SCRIPT_PARAM_SLICE, 100, 50, 500)
  282. if VIP_USER and FileExist(LIB_PATH.."Selector.lua") then
  283. self.SxOrbMenu.generalsettings:addParam("Selector", self:GetText("VIPSELECTOR"), SCRIPT_PARAM_ONOFF, false)
  284. end
  285.  
  286. self.SxOrbMenu:addSubMenu(self:GetText("FARM_SETTINGS"), "farmsettings")
  287. self.SxOrbMenu.farmsettings:addParam("FarmDelay", self:GetText("FARMDELAY"), SCRIPT_PARAM_SLICE, 0, -150, 150)
  288. self.SxOrbMenu.farmsettings:addParam("WindUpTime", self:GetText("WINDUPTIME"), SCRIPT_PARAM_SLICE, 0, -150, 150)
  289. self.SxOrbMenu.farmsettings:addParam("farmoverharass", self:GetText("FARMOVERHARASS"), SCRIPT_PARAM_ONOFF, true)
  290. self.SxOrbMenu.farmsettings:addParam("spellfarm", self:GetText("SPELLFARM"), SCRIPT_PARAM_ONOFF, true)
  291.  
  292. self.SxOrbMenu:addSubMenu(self:GetText("MASTERY_SETTINGS"), "masterysettings")
  293. self.SxOrbMenu.masterysettings:addParam("Butcher", self:GetText("BUTCHER"), SCRIPT_PARAM_ONOFF, false)
  294. self.SxOrbMenu.masterysettings:addParam("Havoc", self:GetText("HAVOC"), SCRIPT_PARAM_ONOFF, false)
  295. self.SxOrbMenu.masterysettings:addParam("ArcaneBlade", self:GetText("ARCANEBLADE"), SCRIPT_PARAM_ONOFF, false)
  296. if self.GotMasteries then
  297. self.SxOrbMenu.masterysettings.Butcher = self.GotButcher == "1"
  298. self.SxOrbMenu.masterysettings.Havoc = self.GotHavoc == "1"
  299. self.SxOrbMenu.masterysettings.ArcaneBlade = self.GotBlade == "1"
  300. end
  301.  
  302. if not NoMenuKeys then
  303. self.SxOrbMenu:addSubMenu(self:GetText("HOTKEY_SETTINGS"), "hotkeysettings")
  304. self.SxOrbMenu.hotkeysettings:addParam("AutoCarry", self:GetText("AUTOCARRY"), SCRIPT_PARAM_ONKEYDOWN, false, 32)
  305. self.SxOrbMenu.hotkeysettings:addParam("MixedMode", self:GetText("MIXEDMODE"), SCRIPT_PARAM_ONKEYDOWN, false, string.byte("C"))
  306. self.SxOrbMenu.hotkeysettings:addParam("LaneClear", self:GetText("LANECLEAR"), SCRIPT_PARAM_ONKEYDOWN, false, string.byte("X"))
  307. self.SxOrbMenu.hotkeysettings:addParam("LastHit", self:GetText("LASTHIT"), SCRIPT_PARAM_ONKEYDOWN, false, string.byte("V"))
  308. end
  309.  
  310. self.SxOrbMenu:addSubMenu(self:GetText("DRAW_SETTINGS"), "drawsettings")
  311. self.SxOrbMenu.drawsettings:addParam("AARange", self:GetText("AARANGE"), SCRIPT_PARAM_ONOFF, false)
  312. self.SxOrbMenu.drawsettings:addParam("MinionHPBar", self:GetText("MINIONHPBAR"), SCRIPT_PARAM_ONOFF, false)
  313. self.SxOrbMenu.drawsettings:addParam("MinionCircle", self:GetText("MINIONCIRCLE"), SCRIPT_PARAM_ONOFF, false)
  314.  
  315. self.SxOrbMenu:addSubMenu(self:GetText("TARGETPRIORITY_SETTINGS"), "targetsettings")
  316. for i, enemy in pairs(GetEnemyHeroes()) do
  317. self.SxOrbMenu.targetsettings:addParam(enemy.charName,enemy.charName, SCRIPT_PARAM_SLICE, 1, 1, #GetEnemyHeroes(), 0)
  318. end
  319. self.SxOrbMenu.targetsettings:addParam("fap","", SCRIPT_PARAM_INFO, "")
  320. self.SxOrbMenu.targetsettings:addParam("fap",self:GetText("TARGETPRIORITY_INFOTEXT_1"), SCRIPT_PARAM_INFO, "")
  321. self.SxOrbMenu.targetsettings:addParam("fap",self:GetText("TARGETPRIORITY_INFOTEXT_2"), SCRIPT_PARAM_INFO, "")
  322. self.SxOrbMenu.targetsettings:addParam("fap",self:GetText("TARGETPRIORITY_INFOTEXT_3"), SCRIPT_PARAM_INFO, "")
  323. self.SxOrbMenu.targetsettings:addParam("fap",self:GetText("TARGETPRIORITY_INFOTEXT_4"), SCRIPT_PARAM_INFO, "")
  324. self:LoadPriority()
  325.  
  326. self.NoMenuKeys = NoMenuKeys
  327. end
  328.  
  329. function SxOrbRaw:GetSummonerInfo(Name, Type, Value)
  330. if Name and Type then
  331. if (Type == "Masteries" or "Mastery") and Value then
  332. return SummonerInfo[Name]["Masteries"][Value]
  333. else
  334. return SummonerInfo[Name][Type]
  335. end
  336. else
  337. return 0
  338. end
  339. end
  340.  
  341. function SxOrbRaw:LoadPriority()
  342. priorityTable = {
  343. AP = {
  344. "Ahri", "Akali", "Anivia", "Annie", "Brand", "Cassiopeia", "Diana", "Evelynn", "FiddleSticks", "Fizz", "Gragas", "Heimerdinger", "Karthus",
  345. "Kassadin", "Katarina", "Kayle", "Kennen", "Leblanc", "Lissandra", "Lux", "Malzahar", "Mordekaiser", "Morgana", "Nidalee", "Orianna",
  346. "Rumble", "Ryze", "Sion", "Swain", "Syndra", "Teemo", "TwistedFate", "Veigar", "Viktor", "Vladimir", "Xerath", "Ziggs", "Zyra", "MasterYi", "Velkoz"
  347. },
  348. Support = {
  349. "Blitzcrank", "Janna", "Karma", "Leona", "Lulu", "Nami", "Sona", "Soraka", "Thresh", "Zilean"
  350. },
  351.  
  352. Tank = {
  353. "Amumu", "Chogath", "DrMundo", "Galio", "Hecarim", "Malphite", "Maokai", "Nasus", "Rammus", "Sejuani", "Shen", "Singed", "Skarner", "Volibear",
  354. "Warwick", "Yorick", "Zac", "Nunu", "Taric", "Alistar", "Braum",
  355. },
  356.  
  357. AD_Carry = {
  358. "Ashe", "Caitlyn", "Corki", "Draven", "Ezreal", "Graves", "Jayce", "KogMaw", "MissFortune", "Pantheon", "Quinn", "Shaco", "Sivir",
  359. "Talon", "Tristana", "Twitch", "Urgot", "Varus", "Vayne", "Zed", "Jinx" , "Lucian", "Yasuo",
  360.  
  361. },
  362.  
  363. Bruiser = {
  364. "Darius", "Elise", "Fiora", "Gangplank", "Garen", "Irelia", "JarvanIV", "Jax", "Khazix", "LeeSin", "Nautilus", "Nocturne", "Olaf", "Poppy",
  365. "Renekton", "Rengar", "Riven", "Shyvana", "Trundle", "Tryndamere", "Udyr", "Vi", "MonkeyKing", "XinZhao", "Aatrox",
  366. },
  367. }
  368. local EnemiesFound = 0
  369. for z=1,#priorityTable.AD_Carry do
  370. for i=1,#GetEnemyHeroes() do
  371. if priorityTable.AD_Carry[z] == self.SxOrbMenu.targetsettings._param[i].text then
  372. self.SxOrbMenu.targetsettings[self.SxOrbMenu.targetsettings._param[i].text] = #GetEnemyHeroes() - EnemiesFound
  373. EnemiesFound = EnemiesFound + 1
  374. end
  375. end
  376. end
  377.  
  378. for z=1,#priorityTable.AP do
  379. for i=1,#GetEnemyHeroes() do
  380. if priorityTable.AP[z] == self.SxOrbMenu.targetsettings._param[i].text then
  381. self.SxOrbMenu.targetsettings[self.SxOrbMenu.targetsettings._param[i].text] = #GetEnemyHeroes() - EnemiesFound
  382. EnemiesFound = EnemiesFound + 1
  383. end
  384. end
  385. end
  386.  
  387. for z=1,#priorityTable.Bruiser do
  388. for i=1,#GetEnemyHeroes() do
  389. if priorityTable.Bruiser[z] == self.SxOrbMenu.targetsettings._param[i].text then
  390. self.SxOrbMenu.targetsettings[self.SxOrbMenu.targetsettings._param[i].text] = #GetEnemyHeroes() - EnemiesFound
  391. EnemiesFound = EnemiesFound + 1
  392. end
  393. end
  394. end
  395.  
  396. for z=1,#priorityTable.Support do
  397. for i=1,#GetEnemyHeroes() do
  398. if priorityTable.Support[z] == self.SxOrbMenu.targetsettings._param[i].text then
  399. self.SxOrbMenu.targetsettings[self.SxOrbMenu.targetsettings._param[i].text] = #GetEnemyHeroes() - EnemiesFound
  400. EnemiesFound = EnemiesFound + 1
  401. end
  402. end
  403. end
  404.  
  405. for z=1,#priorityTable.Tank do
  406. for i=1,#GetEnemyHeroes() do
  407. if priorityTable.Tank[z] == self.SxOrbMenu.targetsettings._param[i].text then
  408. self.SxOrbMenu.targetsettings[self.SxOrbMenu.targetsettings._param[i].text] = #GetEnemyHeroes() - EnemiesFound
  409. EnemiesFound = EnemiesFound + 1
  410. end
  411. end
  412. end
  413. end
  414.  
  415. function SxOrbRaw:OnTick()
  416. if not self.SxOrbMenu.generalsettings.Enabled then return end
  417. self:UpdateMinions()
  418. self:UpdateRange()
  419. if (self.SxOrbMenu.hotkeysettings and self.SxOrbMenu.hotkeysettings.AutoCarry) or _G.SxOrbMenu.AutoCarry then
  420. self:CarryMode("AutoCarry")
  421. end
  422.  
  423. if (self.SxOrbMenu.hotkeysettings and self.SxOrbMenu.hotkeysettings.MixedMode) or _G.SxOrbMenu.MixedMode then
  424. self:CarryMode("MixedMode")
  425. end
  426.  
  427. if (self.SxOrbMenu.hotkeysettings and self.SxOrbMenu.hotkeysettings.LaneClear) or _G.SxOrbMenu.LaneClear then
  428. self:CarryMode("LaneClear")
  429. end
  430.  
  431. if (self.SxOrbMenu.hotkeysettings and self.SxOrbMenu.hotkeysettings.LastHit) or _G.SxOrbMenu.LastHit then
  432. self:CarryMode("LastHit")
  433. end
  434.  
  435. end
  436.  
  437. function SxOrbRaw:UpdateRange()
  438. if not self.SxOrbSettings["RangeChanged"] then
  439. self.SxOrbSettings["TargetRange"] = myHero.range + hitboxes[myHero.charName] + 10
  440. self.SxOrbSettings["LastHitRange"] = myHero.range + hitboxes[myHero.charName] + 10
  441. else
  442. self.SxOrbSettings["LastHitRange"] = myHero.range + hitboxes[myHero.charName] + 10
  443. end
  444. end
  445.  
  446. function SxOrbRaw:ClearMinionTargetStore()
  447. for i, Data in pairs(self.MinionTargetStore) do
  448. local Source = objManager:GetObjectByNetworkId(self.MinionTargetStore[i].SourceMinion)
  449. local Target = objManager:GetObjectByNetworkId(self.MinionTargetStore[i].LastTarget)
  450. if not Source then
  451. table.remove(self.MinionTargetStore, i)
  452. else
  453. if Source.health < 1 then
  454. table.remove(self.MinionTargetStore, i)
  455. end
  456. end
  457. if not Target then
  458. table.remove(self.MinionTargetStore, i)
  459. else
  460. if Target.health < 1 then
  461. table.remove(self.MinionTargetStore, i)
  462. end
  463. end
  464. end
  465. end
  466.  
  467. function SxOrbRaw:UpdateMinions()
  468. self.Minions:update()
  469. self.JungleMinions:update()
  470. self.OtherMinions:update()
  471. end
  472.  
  473. function SxOrbRaw:CarryMode(Mode)
  474. if not self.WaitForAA and self:CanAttack() and self.Attackenabled then
  475. if Mode == "AutoCarry" then
  476. self:AutoCarry()
  477. end
  478.  
  479. if Mode == "MixedMode" then
  480. if self.SxOrbMenu.farmsettings.farmoverharass then
  481. self:LastHit()
  482. if not self.WaitForAA then self:AutoCarry() end
  483. else
  484. self:AutoCarry()
  485. if not self.WaitForAA then self:LastHit() end
  486. end
  487. end
  488.  
  489. if Mode == "LaneClear" then
  490. self:LastHit()
  491. if not self.WaitForAA then self:LaneClear() end
  492. if not self.WaitForAA then self:AutoCarry() end
  493. end
  494.  
  495. if Mode == "LastHit" then
  496. self:LastHit()
  497. end
  498. end
  499.  
  500. if self:CanMove() and not self.WaitForAA then
  501. if not self:CanAttack() and self.Attackenabled and self.SxOrbMenu.farmsettings.spellfarm then
  502. if Mode == "MixedMode" or Mode == "LaneClear" or Mode == "LastHit" then
  503. for index, minion in pairs(self.Minions.objects) do
  504. if self:ValidTarget(minion) and self.MinionToLastHit ~= minion then
  505. local NextAAArriveTick = (self.LastAA + self:GetAnimationTime()) + self:GetFlyTicks(minion) - self:GetLatency() - self:GetWindUpTime()
  506. DmgToMinion, DmgToMinion2 = self:GetPredictDmg(minion, NextAAArriveTick)
  507. if DmgToMinion + DmgToMinion2 > minion.health then
  508. self:KillMinionWithSpell(minion)
  509. end
  510. end
  511. end
  512. end
  513. end
  514. self:OrbWalk()
  515. end
  516. end
  517.  
  518. function SxOrbRaw:KillMinionWithSpell(minion)
  519. local GetDmgTable = { [0] = "Q", [1] = "W", [2] = "E", [3] = "R"}
  520. if self.SpellData and self.SpellData[myHero.charName] then
  521. for i=0,4 do
  522. if self.SpellData[myHero.charName][i] then
  523. if not self.SpellData[myHero.charName][i]["Collision"] then
  524. DmgToMinion, DmgToMinion2 = self:GetPredictDmg(minion, self.SpellData[myHero.charName][i]["Delay"] + (GetDistance(minion)/self.SpellData[myHero.charName][i]["Speed"]))
  525. Dmg, Dmgtype = getDmg(GetDmgTable[i], minion, myHero)
  526. if Dmg > (minion.health - DmgToMinion) then
  527. CastSpell(i, minion)
  528. self.BlockedMinion = minion
  529. self.WaitForAA = false
  530. end
  531. else
  532. -- Collision scheiss
  533. end
  534. end
  535. end
  536. end
  537. end
  538.  
  539. function SxOrbRaw:AutoCarry()
  540. local Target = self:GetTarget()
  541. if Target and self:ValidTarget(Target, true) then
  542. self:StartAttack(Target, true, true)
  543. end
  544. end
  545.  
  546. function SxOrbRaw:LastHit()
  547. for index, minion in pairs(self.Minions.objects) do
  548. if self:ValidTarget(minion) then
  549. if self:IsKillAbleMinion(minion) then break end
  550. end
  551. end
  552. end
  553.  
  554. function SxOrbRaw:LaneClear()
  555. if self.WaitForMinion and self:ValidTarget(self.WaitForMinion) then
  556. if self:IsKillAbleMinion(self.WaitForMinion) then self.WaitForMinion = false end
  557. else
  558. self.WaitForMinion = false
  559. end
  560.  
  561. for index, minion in pairs(self.Minions.objects) do
  562. if self:ValidTarget(minion) and not self.WaitForMinion then
  563. local MyAADmg = self:CalcAADmg(minion)
  564. local MyArriveTick = GetTickCount() + self:GetAnimationTime() + self:GetFlyTicks(minion) + 150
  565. DmgToMinion, DmgToMinion2 = self:GetPredictDmg(minion, MyArriveTick)
  566.  
  567. if DmgToMinion + DmgToMinion2 > minion.health then -- Minion will be dead on my Next AA => Wait for minion
  568. self.WaitForMinion = minion
  569. break
  570. elseif DmgToMinion + DmgToMinion2 + MyAADmg < minion.health then -- Minion will be alive until my Next AA, so its attackable
  571. self:StartAttack(minion)
  572. break
  573. end
  574. end
  575. end
  576.  
  577. for index, minion in pairs(self.JungleMinions.objects) do
  578. if self:ValidTarget(minion) then
  579. self:StartAttack(minion)
  580. break
  581. end
  582. end
  583.  
  584. for index, minion in pairs(self.OtherMinions.objects) do
  585. if self:ValidTarget(minion) then
  586. self:StartAttack(minion)
  587. break
  588. end
  589. end
  590. end
  591.  
  592. function SxOrbRaw:IsKillAbleMinion(minion)
  593. local MyAADmg = self:CalcAADmg(minion)
  594. local MyArriveTick = GetTickCount() + self:GetFlyTicks(minion) - self:GetLatency()
  595. local MyArriveTick2 = GetTickCount() + self:GetAnimationTime() + self:GetFlyTicks(minion) + 150
  596.  
  597. local DmgToMinion = self:GetPredictDmg(minion, MyArriveTick)
  598. local DmgToMinion2, DmgToMinion3 = self:GetPredictDmg(minion, MyArriveTick2)
  599. local VIPMinion = false
  600. if (MyAADmg + DmgToMinion) > minion.health and DmgToMinion < minion.health and (DmgToMinion2 + DmgToMinion3) > minion.health then
  601. VIPMinion = true
  602. self:StartAttack(minion)
  603. return true
  604. end
  605.  
  606. if not VIPMinion and (MyAADmg + DmgToMinion) > minion.health and DmgToMinion < minion.health and (DmgToMinion2 + DmgToMinion3) < minion.health then
  607. self:StartAttack(minion)
  608. return true
  609. end
  610. return false
  611. end
  612.  
  613. function SxOrbRaw:GetPredictDmg(minion, endtick) -- minus = früher, plus = später
  614. local MyArriveTick = endtick
  615. local StartTick = GetTickCount()
  616. local DmgToMinion = 0
  617. local DmgToMinion2 = 0
  618. for i = 1, #self.MinionTargetStore do
  619. if minion.networkID == self.MinionTargetStore[i].LastTarget then
  620. local Source = objManager:GetObjectByNetworkId(self.MinionTargetStore[i].SourceMinion)
  621. local Target = objManager:GetObjectByNetworkId(self.MinionTargetStore[i].LastTarget)
  622. if Source and Source.valid and Source.health > 0 and Target and Target.valid and Target.health > 0 then
  623. local FlyTime = GetDistance(Source, Target) / self.MinionTargetStore[i].ProjectileSpeed
  624. local NextAAStart = self.MinionTargetStore[i].LastAttack + (self.MinionTargetStore[i].LastAttackCD * 1000)
  625. if Source.charName:lower():find("wizard") then Extra = 0 else Extra = 0 end
  626. local ArriveTick = self.MinionTargetStore[i].LastAttack + math.round((FlyTime + self.MinionTargetStore[i].LastWindUpTime)*1000,0) + Extra
  627. local ArriveTick2 = NextAAStart + math.round((FlyTime + self.MinionTargetStore[i].LastWindUpTime)*1000,0) + Extra
  628.  
  629. if ArriveTick > StartTick and ArriveTick < MyArriveTick then
  630. DmgToMinion = DmgToMinion + self.MinionTargetStore[i].SpellDmg
  631. end
  632.  
  633. if ArriveTick2 > StartTick and ArriveTick2 < MyArriveTick then
  634. DmgToMinion2 = DmgToMinion2 + self.MinionTargetStore[i].SpellDmg
  635. end
  636. end
  637. end
  638. end
  639. if minion.charName:lower():find("cannon") and DmgToMinion > 20 then DmgToMinion = DmgToMinion - 20 end
  640. return DmgToMinion, DmgToMinion2
  641. end
  642.  
  643. function SxOrbRaw:LoadExtraFarmSettings()
  644. self.ExtraFarm = 0
  645. if myHero.charName == "Vladimir" then
  646. self.ExtraFarm = 192
  647. end
  648. end
  649.  
  650. function SxOrbRaw:GetFlyTicks(Target)
  651. -- + = Shoot earlier, - = Shoot later
  652. return math.round((((GetDistance(myHero, Target) / (self.projectilespeeds[myHero.charName])) + (1 / (myHero.attackSpeed * self.BaseWindUpTime)))*1000),0) - 200 + self.ExtraFarm
  653. end
  654.  
  655. function SxOrbRaw:StartAttack(Target, NoDelay, AutoCarry)
  656. if NoDelay then
  657. Delay = 0
  658. else
  659. Delay = self.SxOrbMenu.farmsettings.FarmDelay/1000
  660. end
  661. self.WaitForAA = true
  662. DelayAction(function()
  663. self:Attack(Target,AutoCarry)
  664. self:BeforeAttack(Target)
  665. self.MinionToLastHit = Target
  666. end, Delay)
  667. end
  668.  
  669. function SxOrbRaw:Attack(Target, AutoCarry)
  670. myHero:Attack(Target)
  671. if self:ValidTarget(Target,AutoCarry) and self.WaitForAA then
  672. DelayAction(function() self:Attack(Target) end, 0)
  673. else
  674. self.WaitForAA = false
  675. end
  676. end
  677.  
  678. function SxOrbRaw:OrbWalk()
  679. if self:CanMove() then
  680. if self.SxOrbMenu.generalsettings.StopMove then
  681. if GetDistance(mousePos) > self.SxOrbMenu.generalsettings.StopMoveSlider - 20 then
  682. myHero:MoveTo(mousePos.x, mousePos.z)
  683. end
  684. else
  685. MouseMove = Vector(myHero) + (Vector(mousePos) - Vector(myHero)):normalized() * 500
  686. myHero:MoveTo(MouseMove.x, MouseMove.z)
  687. end
  688. end
  689. end
  690.  
  691. function SxOrbRaw:CheckAACancel(AANetwordID)
  692. local AAObj = objManager:GetObjectByNetworkId(AANetwordID)
  693. if AAObj and AAObj.valid then
  694. --
  695. else
  696. if not self:CanMove(100) then
  697. DelayAction(function() self:CheckAACancel(AANetwordID) end, 0)
  698. else
  699. self.WaitForAA = false
  700. end
  701. end
  702. end
  703.  
  704. function SxOrbRaw:OnDraw()
  705. if self.SxOrbMenu.drawsettings.AARange then
  706. self:CircleDraw(myHero.x, myHero.y, myHero.z, self.SxOrbSettings["LastHitRange"] + 30, 4294967295)
  707. end
  708.  
  709. if self.SxOrbMenu.drawsettings.MinionHPBar then
  710. self:DrawMinionHPBar()
  711. end
  712.  
  713. if self.SxOrbMenu.drawsettings.MinionCircle then
  714. for index, minion in pairs(self.Minions.objects) do
  715. if ValidTarget(minion, 2000) and minion.health > 0 then
  716. local MyAADmg = self:CalcAADmg(minion)
  717. local MyArriveTick = GetTickCount() + self:GetFlyTicks(minion) - self:GetLatency()
  718. local DmgToMinion = self:GetPredictDmg(minion, MyArriveTick)
  719. if (MyAADmg + DmgToMinion) > math.floor(minion.health) then
  720. local MinionFound = false
  721. for i=1,#self.KillAbleMinions do
  722. if self.KillAbleMinions[1] == minion then
  723. MinionFound = true
  724. break
  725. end
  726. end
  727. if not MinionFound then
  728. table.insert(self.KillAbleMinions, minion)
  729. end
  730. end
  731. end
  732. end
  733.  
  734. for i=1,#self.KillAbleMinions do
  735. if self.KillAbleMinions[i] and self.KillAbleMinions[i].health == 0 then
  736. table.remove(self.KillAbleMinions, i)
  737. else
  738. if self.KillAbleMinions[i] and self.KillAbleMinions[i].x and self.KillAbleMinions[i].y and self.KillAbleMinions[i].z then
  739. self:CircleDraw(self.KillAbleMinions[i].x, self.KillAbleMinions[i].y, self.KillAbleMinions[i].z, 150, 4294967295)
  740. end
  741. end
  742. end
  743. end
  744.  
  745. if self.SxOrbMenu.generalsettings.StopMoveCircle then
  746. self:CircleDraw(myHero.x, myHero.y, myHero.z, self.SxOrbMenu.generalsettings.StopMoveSlider, 4294967295)
  747. end
  748.  
  749. --~ if self.WaitForMinion then
  750. --~ self:CircleDraw(self.WaitForMinion.x, self.WaitForMinion.y, self.WaitForMinion.z, 100, 4294967295)
  751. --~ end
  752.  
  753. --~ if self.TrackMinion then
  754. --~ local Source = objManager:GetObjectByNetworkId(self.TrackMinion.SourceMinion)
  755. --~ local Target = objManager:GetObjectByNetworkId(self.TrackMinion.LastTarget)
  756. --~ if Target and Target.valid and Target.health > 0 then
  757. --~ self:CircleDraw(Source.x, Source.y, Source.z, 100, 4294967295)
  758. --~ local FlyTime = GetDistance(Source, Target) / self.TrackMinion.ProjectileSpeed
  759. --~ local ArriveTick = self.TrackMinion.LastAttack + math.round((FlyTime + self.TrackMinion.LastWindUpTime)*1000,0)
  760. --~ if GetTickCount() > ArriveTick - 70 - self:GetLatency() then
  761. --~ self:CircleDraw(Target.x, Target.y, Target.z, 100, 4294967295)
  762. --~ end
  763.  
  764. --~ if GetTickCount() > ArriveTick + 500 then
  765. --~ self.TrackMinion = nil
  766. --~ end
  767. --~ else
  768. --~ self.TrackMinion = nil
  769. --~ end
  770. --~ end
  771. end
  772.  
  773. function SxOrbRaw:DisableAttacks()
  774. self.Attackenabled = false
  775. end
  776.  
  777. function SxOrbRaw:EnableAttacks()
  778. self.Attackenabled = false
  779. end
  780.  
  781. function SxOrbRaw:BeforeAttack(target)
  782. local result = false
  783. for i, cb in ipairs(self.BeforeAttackCallbacks) do
  784. local ri = cb(target)
  785. if ri then
  786. result = true
  787. end
  788. end
  789. return result
  790. end
  791.  
  792. function SxOrbRaw:RegisterBeforeAttackCallback(f)
  793. table.insert(self.BeforeAttackCallbacks, f)
  794. end
  795.  
  796. function SxOrbRaw:OnAttack(target)
  797. for i, cb in ipairs(self.OnAttackCallbacks) do
  798. cb(target)
  799. end
  800. end
  801.  
  802. function SxOrbRaw:RegisterOnAttackCallback(f)
  803. table.insert(self.OnAttackCallbacks, f)
  804. end
  805.  
  806. function SxOrbRaw:AfterAttack(target)
  807. for i, cb in ipairs(self.AfterAttackCallbacks) do
  808. cb(target)
  809. end
  810. end
  811.  
  812. function SxOrbRaw:RegisterAfterAttackCallback(f)
  813. table.insert(self.AfterAttackCallbacks, f)
  814. end
  815.  
  816. function SxOrbRaw:SpellResetCallback()
  817. for i, cb in ipairs(self.SpellResetCallbacks) do
  818. cb()
  819. end
  820. end
  821.  
  822. function SxOrbRaw:RegisterSpellResetCallback(f)
  823. table.insert(self.SpellResetCallbacks, f)
  824. end
  825.  
  826. function SxOrbRaw:RegisterHotKey(Mode, MainMenu, SubMenu)
  827. if Mode:lower() == "autocarry" or Mode:lower() == "mixedmode" or Mode:lower() == "laneclear" or Mode:lower() == "lasthit" then
  828. if Mode:lower() == "autocarry" then table.insert(self.HotKeys["AutoCarry"], {MainMenu,SubMenu}) end
  829. if Mode:lower() == "mixedmode" then table.insert(self.HotKeys["MixedMode"], {MainMenu,SubMenu}) end
  830. if Mode:lower() == "laneclear" then table.insert(self.HotKeys["LaneClear"], {MainMenu,SubMenu}) end
  831. if Mode:lower() == "lasthit" then table.insert(self.HotKeys["LastHit"], {MainMenu,SubMenu}) end
  832. else
  833. print("Error: Unknown Mode: "..Mode)
  834. end
  835. end
  836.  
  837. function SxOrbRaw:HotKeyCallback()
  838. for i=1,#self.HotKeys["AutoCarry"] do
  839. if not self.HotKeys["AutoCarry"][i][1][tostring(self.HotKeys["AutoCarry"][i][2])] then
  840. _G.SxOrbMenu.AutoCarry = false
  841. break
  842. else
  843. _G.SxOrbMenu.AutoCarry = true
  844. end
  845. end
  846. for i=1,#self.HotKeys["MixedMode"] do
  847. if not self.HotKeys["MixedMode"][i][1][tostring(self.HotKeys["MixedMode"][i][2])] then
  848. _G.SxOrbMenu.MixedMode = false
  849. break
  850. else
  851. _G.SxOrbMenu.MixedMode = true
  852. end
  853. end
  854. for i=1,#self.HotKeys["LaneClear"] do
  855. if not self.HotKeys["LaneClear"][i][1][tostring(self.HotKeys["LaneClear"][i][2])] then
  856. _G.SxOrbMenu.LaneClear = false
  857. break
  858. else
  859. _G.SxOrbMenu.LaneClear = true
  860. end
  861. end
  862. for i=1,#self.HotKeys["LastHit"] do
  863. if not self.HotKeys["LastHit"][i][1][tostring(self.HotKeys["LastHit"][i][2])] then
  864. _G.SxOrbMenu.LastHit = false
  865. break
  866. else
  867. _G.SxOrbMenu.LastHit = true
  868. end
  869. end
  870. end
  871.  
  872. function SxOrbRaw:DrawCircleNextLvl(x, y, z, radius, width, color, chordlength)
  873. radius = radius or 300
  874. quality = math.max(8,math.floor(180/math.deg((math.asin((chordlength/(2*radius)))))))
  875. quality = 2 * math.pi / quality
  876. radius = radius*.92
  877. local points = {}
  878. for theta = 0, 2 * math.pi + quality, quality do
  879. local c = WorldToScreen(D3DXVECTOR3(x + radius * math.cos(theta), y, z - radius * math.sin(theta)))
  880. points[#points + 1] = D3DXVECTOR2(c.x, c.y)
  881. end
  882. DrawLines2(points, width or 1, color or 4294967295)
  883. end
  884.  
  885. function SxOrbRaw:DrawCircle2(x, y, z, radius, color)
  886. local vPos1 = Vector(x, y, z)
  887. local vPos2 = Vector(cameraPos.x, cameraPos.y, cameraPos.z)
  888. local tPos = vPos1 - (vPos1 - vPos2):normalized() * radius
  889. local sPos = WorldToScreen(D3DXVECTOR3(tPos.x, tPos.y, tPos.z))
  890. if OnScreen({ x = sPos.x, y = sPos.y }, { x = sPos.x, y = sPos.y }) then
  891. self:DrawCircleNextLvl(x, y, z, radius, 1, color, 75)
  892. end
  893. end
  894.  
  895. function SxOrbRaw:CircleDraw(x,y,z,radius, color)
  896. self:DrawCircle2(x, y, z, radius, color)
  897. end
  898.  
  899. function SxOrbRaw:CalcAADmg(minion)
  900. local RawDMG = myHero:CalcDamage(minion)
  901. RawDMG = RawDMG + self:BonusDamage(minion)
  902. if self.SxOrbMenu.masterysettings.Havoc then
  903. RawDMG = RawDMG*1.03
  904. end
  905. if self.SxOrbMenu.masterysettings.Butcher then
  906. RawDMG = RawDMG + 2
  907. end
  908. if self.SxOrbMenu.masterysettings.ArcaneBlade then
  909. RawDMG = RawDMG + myHero.ap * 0.05
  910. end
  911. return RawDMG
  912. end
  913.  
  914. function SxOrbRaw:BonusDamage(minion)
  915. local AD = myHero:CalcDamage(minion, myHero.totalDamage)
  916. local BONUS = 0
  917. if myHero.charName == 'Vayne' then
  918. if myHero:GetSpellData(_Q).level > 0 and myHero:CanUseSpell(_Q) == SUPRESSED then
  919. BONUS = BONUS + myHero:CalcDamage(minion, ((0.05 * myHero:GetSpellData(_Q).level) + 0.25 ) * myHero.totalDamage)
  920. end
  921. if not VayneCBAdded then
  922. VayneCBAdded = true
  923. function VayneParticle(obj)
  924. if GetDistance(obj) < 1000 and obj.name:lower():find("vayne_w_ring2.troy") then
  925. VayneWParticle = obj
  926. end
  927. end
  928. AddCreateObjCallback(VayneParticle)
  929. end
  930. if VayneWParticle and VayneWParticle.valid and GetDistance(VayneWParticle, minion) < 10 then
  931. BONUS = BONUS + 10 + 10 * myHero:GetSpellData(_W).level + (0.03 + (0.01 * myHero:GetSpellData(_W).level)) * minion.maxHealth
  932. end
  933. elseif myHero.charName == 'Teemo' and myHero:GetSpellData(_E).level > 0 then
  934. BONUS = BONUS + myHero:CalcMagicDamage(minion, (myHero:GetSpellData(_E).level * 10) + (myHero.ap * 0.3) )
  935. elseif myHero.charName == 'Corki' then
  936. BONUS = BONUS + myHero.totalDamage/10
  937. elseif myHero.charName == 'MissFortune' and myHero:GetSpellData(_W).level > 0 then
  938. BONUS = BONUS + myHero:CalcMagicDamage(minion, (4 + 2 * myHero:GetSpellData(_W).level) + (myHero.ap/20))
  939. elseif myHero.charName == 'Varus' and myHero:GetSpellData(_W).level > 0 then
  940. BONUS = BONUS + (6 + (myHero:GetSpellData(_W).level * 4) + (myHero.ap * 0.25))
  941. elseif myHero.charName == 'Caitlyn' then
  942. if not CallbackCaitlynAdded then
  943. function CaitlynParticle(obj)
  944. if GetDistance(obj) < 100 and obj.name:lower():find("headshot_rdy_indicator") then
  945. HeadShotParticle = obj
  946. end
  947. end
  948. AddCreateObjCallback(CaitlynParticle)
  949. CallbackCaitlynAdded = true
  950. end
  951. if HeadShotParticle and HeadShotParticle.valid then
  952. BONUS = BONUS + AD * 1.5
  953. end
  954. elseif myHero.charName == 'Orianna' then
  955. BONUS = BONUS + myHero:CalcMagicDamage(minion, 10 + (8 * (math.ceil(myHero.level / 3)-1)) + (myHero.ap * 0.15))
  956. elseif myHero.charName == 'TwistedFate' then
  957. if not TFCallbackAdded then
  958. function TFParticle(obj)
  959. if GetDistance(obj) < 100 and obj.name:lower():find("cardmaster_stackready.troy") then
  960. TFEParticle = obj
  961. elseif GetDistance(obj) < 100 and obj.name:lower():find("card_blue.troy") then
  962. TFWParticle = obj
  963. end
  964. end
  965. AddCreateObjCallback(TFParticle)
  966. TFCallbackAdded = true
  967. end
  968. if TFEParticle and TFEParticle.valid then
  969. BONUS = BONUS + myHero:CalcMagicDamage(minion, myHero:GetSpellData(_E).level * 15 + 40 + 0.5 * myHero.ap)
  970. end
  971. if TFWParticle and TFWParticle.valid then
  972. BONUS = BONUS + math.max(myHero:CalcMagicDamage(minion, myHero:GetSpellData(_W).level * 20 + 20 + 0.5 * myHero.ap) - 40, 0)
  973. end
  974. elseif myHero.charName == 'Draven' then
  975. if TargetHaveBuff("dravenspinning", myHero) then
  976. BONUS = BONUS + AD * (0.35 + (0.10 * myHero:GetSpellData(_Q).level))
  977. end
  978. elseif myHero.charName == 'Nasus' and VIP_USER then
  979. if myHero:GetSpellData(_Q).level > 0 and myHero:CanUseSpell(_Q) == SUPRESSED then
  980. local Qdamage = {30, 50, 70, 90, 110}
  981. NasusQStacks = NasusQStacks or 0
  982. BONUS = BONUS + myHero:CalcDamage(minion, 10 + 20 * (myHero:GetSpellData(_Q).level) + NasusQStacks)
  983. if not RecvPacketNasusAdded then
  984. function NasusOnRecvPacket(p)
  985. if p.header == 0xFE and p.size == 0xC then
  986. p.pos = 1
  987. pNetworkID = p:DecodeF()
  988. unk01 = p:Decode2()
  989. unk02 = p:Decode1()
  990. stack = p:Decode4()
  991. if pNetworkID == myHero.networkID then
  992. NasusQStacks = stack
  993. end
  994. end
  995. end
  996. RecvPacketNasusAdded = true
  997. AddRecvPacketCallback(NasusOnRecvPacket)
  998. end
  999. end
  1000. elseif myHero.charName == "Ziggs" then
  1001. if not CallbackZiggsAdded then
  1002. function ZiggsParticle(obj)
  1003. if GetDistance(obj) < 100 and obj.name:lower():find("ziggspassive") then
  1004. ZiggsParticleObj = obj
  1005. end
  1006. end
  1007. AddCreateObjCallback(ZiggsParticle)
  1008. CallbackZiggsAdded = true
  1009. end
  1010. if ZiggsParticleObj and ZiggsParticleObj.valid then
  1011. local base = {20, 24, 28, 32, 36, 40, 48, 56, 64, 72, 80, 88, 100, 112, 124, 136, 148, 160}
  1012. BONUS = BONUS + myHero:CalcMagicDamage(minion, base[myHero.level] + (0.25 + 0.05 * (myHero.level % 7)) * myHero.ap)
  1013. end
  1014. elseif myHero.charName == "KogMaw" then
  1015. if TargetHaveBuff("KogMawBioArcaneBarrage", myHero) then
  1016. BONUS = BONUS + myHero:CalcMagicDamage(minion, minion.health * (0.01 + (myHero.level * 0.01) + (myHero.ap * 0.01)))
  1017. end
  1018. elseif myHero.charName == "Lulu" and not self.DeactivateLuluPassive then
  1019. local base = {9,21,33,45,57,69,81,93,105}
  1020. BONUS = BONUS + myHero:CalcMagicDamage(minion, base[math.ceil(myHero.level/2)] + (myHero.ap * 0.05))
  1021. end
  1022. return BONUS
  1023. end
  1024.  
  1025. function SxOrbRaw:GetAnimationTime()
  1026. return (1 / (myHero.attackSpeed * self.BaseAnimationTime)*1000) - self:GetLatency()
  1027. end
  1028.  
  1029. function SxOrbRaw:GetWindUpTime()
  1030. return (1 / (myHero.attackSpeed * self.BaseWindUpTime)*1000)
  1031. end
  1032.  
  1033. function SxOrbRaw:GetLatency()
  1034. return GetLatency()/2
  1035. end
  1036.  
  1037. function SxOrbRaw:CanAttack()
  1038. if GetTickCount() > (self.LastAA + self:GetAnimationTime() - self:GetLatency()) and not self.DontInterrupt and not _G.SxOrbMenu.WaitForInterruptSpell then
  1039. return true
  1040. else
  1041. return false
  1042. end
  1043. end
  1044.  
  1045. function SxOrbRaw:CanMove()
  1046. if GetTickCount() > (self.LastAction + self:GetWindUpTime() - self:GetLatency() + self.SxOrbMenu.farmsettings.WindUpTime + 10) and not self.DontInterrupt and not _G.SxOrbMenu.WaitForInterruptSpell then
  1047. return true
  1048. else
  1049. return false
  1050. end
  1051. end
  1052.  
  1053. function SxOrbRaw:IsCasting()
  1054. if GetTickCount() > (self.LastAction + self:GetWindUpTime() - self:GetLatency() + self.SxOrbMenu.farmsettings.WindUpTime + 10) and not self.DontInterrupt and not _G.SxOrbMenu.WaitForInterruptSpell and not self.WaitForAA then
  1055. return true
  1056. else
  1057. return false
  1058. end
  1059. end
  1060.  
  1061. function SxOrbRaw:CheckWaitForBuff()
  1062. if self.WaitForBuff and self.DontInterrupt and self.DontInterruptSpells[myHero.charName] and self.DontInterruptSpells[myHero.charName]["Buff"] and TargetHaveBuff(self.DontInterruptSpells[myHero.charName]["Buff"], myHero) then
  1063. self.WaitForBuff = false
  1064. self.WaitForBuffEnd = true
  1065. for i = 1, myHero.buffCount do
  1066. local buff = myHero:getBuff(i)
  1067. if buff and buff.valid and buff.name == self.DontInterruptSpells[myHero.charName]["Buff"] then
  1068. BuffNumber = i
  1069. end
  1070. end
  1071. end
  1072.  
  1073. if self.WaitForBuffEnd and BuffNumber then
  1074. local Buff = myHero:getBuff(BuffNumber)
  1075. if not(Buff.valid) then
  1076. self.DontInterrupt = false
  1077. self.WaitForBuffEnd = false
  1078. BuffNumber = nil
  1079. end
  1080. end
  1081.  
  1082. if self.WaitForUlt and self.WaitForUltTick > GetTickCount() + 100 then
  1083. self.DontInterrupt = false
  1084. end
  1085. end
  1086.  
  1087. function SxOrbRaw:OnWndMsg(msg, key)
  1088. if (myHero.charName == "MissFortune" or myHero.charName == "Katarina") and myHero:CanUseSpell(_R) == READY and key == 82 then
  1089. self.DontInterrupt = true
  1090. self.WaitForUlt = true
  1091. self.WaitForUltTick = GetTickCount()
  1092. end
  1093. end
  1094.  
  1095. function SxOrbRaw:OnCreateObj(obj)
  1096. if self.WaitForBuff and self.DontInterrupt and self.DontInterruptSpells[myHero.charName] and self.DontInterruptSpells[myHero.charName]["Object"] and obj.name == self.DontInterruptSpells[myHero.charName]["Object"] and GetDistanceSqr(obj) < 3600 then
  1097. self.WaitForBuffEnd = true
  1098. self.WaitForObjEnd = obj
  1099. end
  1100. end
  1101.  
  1102. function SxOrbRaw:OnDeleteObj(obj)
  1103. if self.WaitForBuffEnd and obj == self.WaitForObjEnd then
  1104. self.DontInterrupt = false
  1105. self.WaitForBuffEnd = false
  1106. end
  1107. end
  1108.  
  1109. function SxOrbRaw:ResetAA()
  1110. self.WaitForAA = false
  1111. self.LastAction = 0
  1112. self.LastAA = 0
  1113. self:SpellResetCallback()
  1114. end
  1115.  
  1116. function SxOrbRaw:GetHitBox(name)
  1117. return hitboxes[name] or 0
  1118. end
  1119.  
  1120. function SxOrbRaw:OnProcessSpell(unit, spell)
  1121. if unit.isMe then
  1122. --~ print(spell.name)
  1123. if self.DontInterruptSpells[myHero.charName] and self.DontInterruptSpells[myHero.charName]["Spell"] == spell.name then
  1124. self.WaitForUlt = false
  1125. self.DontInterrupt = true
  1126. self.WaitForBuff = true
  1127. _G.SxOrbMenu.WaitForInterruptSpell = false
  1128. end
  1129. self.WaitForAA = false
  1130. self.LastAction = GetTickCount()
  1131. if spell.target then self.LastTarget = spell.target end
  1132. if (spell.name:lower():find("attack") or self.IsBasicAttack[spell.name]) then
  1133. self.LastAA = GetTickCount()
  1134. self.BaseAnimationTime = 1 / (spell.animationTime * myHero.attackSpeed)
  1135. self.BaseWindUpTime = 1 / (spell.windUpTime * myHero.attackSpeed)
  1136. self:CheckAACancel(spell.projectileID)
  1137. self:OnAttack(self.LastTarget)
  1138. DelayAction(function() self:AfterAttack(self.LastTarget) end, spell.windUpTime - (GetLatency()/2000) + self.SxOrbMenu.farmsettings.WindUpTime / 1000)
  1139. end
  1140.  
  1141. if self.ResetSpells[spell.name] then
  1142. --~ print("reset")
  1143. self.WaitForAA = false
  1144. self.LastAction = GetTickCount()
  1145. self.LastAA = GetTickCount() - self:GetAnimationTime() + self:GetWindUpTime() - self:GetLatency()
  1146. DelayAction(function() self:SpellResetCallback() end, (self:GetWindUpTime() - self:GetLatency() + self.SxOrbMenu.farmsettings.WindUpTime)/1000)
  1147. end
  1148.  
  1149. if myHero.charName == "Lulu" and spell.name == "LuluE" and not spell.target.isMe then
  1150. self.DeactivateLuluPassive = true
  1151. if spell.target.team == myHero.team then
  1152. DelayAction(function() self.DeactivateLuluPassive = false end, 6)
  1153. else
  1154. DelayAction(function() self.DeactivateLuluPassive = false end, 4)
  1155. end
  1156. end
  1157. end
  1158. end
  1159.  
  1160. function SxOrbRaw:GetMinionTargets(unit, spell)
  1161. if spell and spell.name and spell.name:lower():find("attack") and unit and unit.networkID and unit.type == "obj_AI_Minion" and spell.target and spell.target.type == "obj_AI_Minion" and unit.team == myHero.team then
  1162. local Data = {SourceMinion = unit.networkID, LastAttack = GetTickCount(), LastTarget = spell.target.networkID, LastAttackCD = spell.animationTime, Unit = unit, LastWindUpTime = spell.windUpTime, ProjectileSpeed = self.projectilespeeds[unit.charName], SpellDmg = unit:CalcDamage(spell.target)}
  1163. table.insert(self.MinionTargetStore, Data)
  1164. if unit.charName:lower():find("wizard") and not self.TrackMinion and GetDistance(unit) < 2000 and GetTarget() and unit == GetTarget() then
  1165. self.TrackMinion = Data
  1166. end
  1167.  
  1168. end
  1169. end
  1170.  
  1171. function SxOrbRaw:GetAACount(enemy)
  1172. EnemyHP = math.ceil(enemy.health)
  1173. if myHero.charName == "Vayne" then
  1174. if myHero:GetSpellData(_W).level > 0 then TargetTrueDmg = math.floor((((enemy.maxHealth/100)*(3+(myHero:GetSpellData(_W).level)))+(10+(myHero:GetSpellData(_W).level)*10))/3) else TargetTrueDmg = 0 end
  1175. AADMG = math.floor((math.floor(myHero.totalDamage)) * 100 / (100 + enemy.armor)) + TargetTrueDmg
  1176. DMGThisAA = AADMG + TargetTrueDmg
  1177. NeededAA = math.ceil(EnemyHP / DMGThisAA)
  1178. NeededAARoundDown = (math.floor(NeededAA/3))*3
  1179. DMGWithAA = NeededAARoundDown * DMGThisAA
  1180. PredictHP = EnemyHP - DMGWithAA
  1181. RestAA = math.ceil(PredictHP / AADMG)
  1182.  
  1183. if RestAA > 2 then
  1184. return NeededAA
  1185. else
  1186. return NeededAARoundDown + RestAA
  1187. end
  1188. else
  1189. AADMG = math.floor((math.floor(myHero.totalDamage)) * 100 / (100 + enemy.armor))
  1190. NeededAA = math.ceil(EnemyHP / AADMG)
  1191. return NeededAA
  1192. end
  1193. end
  1194.  
  1195. function SxOrbRaw:ValidTarget(Target,AutoCarry)
  1196. if AutoCarry then MyRange = self.SxOrbSettings["TargetRange"] + (hitboxes[Target.charName] or 0) else MyRange = self.SxOrbSettings["LastHitRange"] + (hitboxes[Target.charName] or 0) end
  1197. if Target and Target.health > 0 and ValidTarget(Target) and Target.team ~= myHero.team and GetDistanceSqr(Target) < MyRange * MyRange then
  1198. return true
  1199. else
  1200. return false
  1201. end
  1202. end
  1203.  
  1204. function SxOrbRaw:ChangeSettings(SettingsName, SettingValue)
  1205. if self.SxOrbSettings and self.SxOrbSettings[SettingsName] then
  1206. if SettingValue then
  1207. if SettingsName == "TargetRange" then self.SxOrbSettings["RangeChanged"] = true end
  1208. self.SxOrbSettings[SettingsName] = SettingValue
  1209. else
  1210. return self.SxOrbSettings[SettingsName]
  1211. end
  1212. end
  1213. end
  1214.  
  1215. function SxOrbRaw:GetTarget()
  1216. local SelectedTarget = GetTarget()
  1217. local TargetTable = { ["Hero"] = nil, ["AA"] = math.huge }
  1218. if SelectedTarget and SelectedTarget.type == myHero.type and self:ValidTarget(SelectedTarget) then
  1219. return SelectedTarget
  1220. else
  1221. if (self.SxOrbMenu.generalsettings.Selector or self.SxOrbSettings["ForceSelector"]) and FileExist(LIB_PATH.."Selector.lua") and VIP_USER then
  1222. if not SelectorInit then
  1223. require("Selector")
  1224. Selector.Instance()
  1225. SelectorInit = true
  1226. end
  1227. SelectorTarget = Selector.GetTarget(SelectorMenu.Get().mode, nil, {distance = self.SxOrbSettings["TargetRange"]})
  1228. if SelectorTarget and self:ValidTarget(SelectorTarget) then
  1229. return SelectorTarget
  1230. end
  1231. else
  1232. for i, enemy in pairs(GetEnemyHeroes()) do
  1233. if self:ValidTarget(enemy) then
  1234. NeededAA = self:GetAACount(enemy)
  1235. if (NeededAA < TargetTable.AA) or (NeededAA == TargetTable.AA and self.SxOrbMenu.targetsettings[enemy.charName] > self.SxOrbMenu.targetsettings[TargetTable["Hero"].charName]) then
  1236. TargetTable.AA = NeededAA
  1237. TargetTable.Hero = enemy
  1238. end
  1239. end
  1240. end
  1241. return TargetTable["Hero"]
  1242. end
  1243. end
  1244. end
  1245.  
  1246. function SxOrbRaw:DrawRectangleAL(x, y, w, h, color)
  1247. local Points = {}
  1248. Points[1] = D3DXVECTOR2(math.floor(x), math.floor(y))
  1249. Points[2] = D3DXVECTOR2(math.floor(x + w), math.floor(y))
  1250. DrawLines2(Points, math.floor(h), color)
  1251. end
  1252.  
  1253. function SxOrbRaw:DrawMinionHPBar()
  1254. for i,minion in pairs(self.Minions.objects) do
  1255. if GetDistanceSqr(minion) < 1000*1000 then
  1256. local MinionBarPos = GetUnitHPBarPos(minion)
  1257. local MyDmgToMinion = self:CalcAADmg(minion)
  1258. local DrawDistance = math.floor(63 / (minion.maxHealth / MyDmgToMinion))
  1259. --~ for i=1,math.ceil(minion.health / MyDmgToMinion) do
  1260. self:DrawRectangleAL(MinionBarPos.x - 32 + DrawDistance * 1, MinionBarPos.y, 1, 4, 4278190080)
  1261. --~ end
  1262. end
  1263. end
  1264. end
  1265.  
  1266. SxOrb = SxOrbRaw()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement