private static void Drawing_OnEndScene(EventArgs args) { if (!LoadTracker.Enabled) { return; } foreach (var item in GameObjects.EnemyHeroes) { var target = item; var histracker = TrackerHelp.Where(i => i.Unit.NetworkId == target.NetworkId).FirstOrDefault(); if (histracker != null) { if (histracker.InValidPosition.DistanceToPlayer() <= 3000) { var line = new Geometry.Line(ObjectManager.Player.Position, histracker.InValidPosition); line.Draw(System.Drawing.Color.Red); } if (histracker.ValidPosition.IsOnScreen() || histracker.InValidPosition.IsOnScreen()) { if (histracker.InValidPosition.IsOnScreen()) { var pos = Drawing.WorldToScreen(histracker.InValidPosition); Drawing.DrawText(pos.X, pos.Y, System.Drawing.Color.Yellow, target.CharacterName); Render.Circle.DrawCircle(histracker.InValidPosition, 50, System.Drawing.Color.Red); } if (histracker.ValidPosition.IsOnScreen() && histracker.ValidPosition.Distance(histracker.InValidPosition) > histracker.Unit.BoundingRadius) { var pos = Drawing.WorldToScreen(histracker.ValidPosition); Drawing.DrawText(pos.X, pos.Y, System.Drawing.Color.Yellow, target.CharacterName); Render.Circle.DrawCircle(histracker.ValidPosition, 50, System.Drawing.Color.Green); } /*if (histracker.InValidPosition.Distance(histracker.ValidPosition) > histracker.Unit.BoundingRadius) * { * var line = new Geometry.Line(histracker.InValidPosition, histracker.ValidPosition); * line.Draw(System.Drawing.Color.Blue); * }*/ /*if (histracker.InValidPosition.Distance(histracker.ValidPosition) > histracker.Unit.BoundingRadius) * { * * } * else * { * * }*/ } } } }
private static void Game_OnUpdate(EventArgs args) { if (!ObjectManager.Player.HasBuff("SionR")) { return; } var obj = new GameObject(); var pos = ObjectManager.Player.Position.Extend(Game.CursorPos, 1000); Geometry.Line line = new Geometry.Line(ObjectManager.Player.Position, pos); line.Draw(Color.White, 200); foreach (var l in line.Points) { if (obj.Position.Distance(l) < 100) { Orbwalker.Attack((AIBaseClient)obj); } } }