Exemplo n.º 1
0
        public override void Draw()
        {
            if (DrawMenu.CheckBoxValue("dmg"))
            {
                foreach (var obj in EntityManager.Heroes.Enemies.Where(o => o.IsValidTarget()))
                {
                    float x = obj.HPBarPosition.X;
                    float y = obj.HPBarPosition.Y;
                    dmg.Color = Color.White;
                    if (ComboDamage(obj, true) >= obj.Health)
                    {
                        dmg.Color = Color.Red;
                    }
                    dmg.TextValue = (int)ComboDamage(obj, true) + " / " + (int)obj.Health;
                    dmg.Position  = new Vector2(x, y);
                    dmg.Draw();
                }
            }

            if (DrawMenu.CheckBoxValue("balls"))
            {
                foreach (var ball in BallsList.Where(b => b != null && E.IsInRange(b)))
                {
                    Circle.Draw(SharpDX.Color.AliceBlue, ball.BoundingRadius + 25, ball);

                    if (E.IsReady())
                    {
                        var start = ball.ServerPosition.Extend(user.ServerPosition, 100).To3D();
                        var end   = user.ServerPosition.Extend(ball.ServerPosition, Eball.Range).To3D();

                        new Geometry.Polygon.Rectangle(start, end, Eball.Width).Draw(Color.AliceBlue);
                    }
                }
            }

            foreach (var spell in SpellList.Where(s => DrawMenu.CheckBoxValue(s.Slot)))
            {
                Circle.Draw(spell.IsReady() ? SharpDX.Color.Chartreuse : SharpDX.Color.OrangeRed, spell.Range, user);
            }
        }
Exemplo n.º 2
0
        internal static Obj_AI_Minion SelectBall(Obj_AI_Base target)
        {
            if (target == null)
            {
                return(null);
            }

            Obj_AI_Minion theball      = null;
            var           CastPosition = Syndra.Q.GetPrediction(target).CastPosition;

            foreach (var ball in BallsList.Where(b => b != null && Syndra.E.IsInRange(b)))
            {
                var source = Player.Instance.PredictPosition();
                var start  = ball.ServerPosition.Extend(source, 100).To3D();
                var end    = source.Extend(ball.ServerPosition, Syndra.Eball.Range).To3D();
                var rect   = new Geometry.Polygon.Rectangle(start, end, Syndra.Eball.Width);
                if (rect.IsInside(CastPosition))
                {
                    theball = ball;
                }
            }
            return(theball);
        }