protected override void Draw(GameTime gameTime)
        {
            this.GraphicsDevice.Clear(Color.CornflowerBlue);

            _spriteBatch.Begin();

            curve.DrawWithSpriteBatch(_spriteBatch, _font, gameTime);

            if (isMouseNearCp)
            {
                var col = Color.Blue;
                if (selectedCp == mouseNearCpNumber)
                {
                    col = Color.Red;
                }
                DrawHelpers.DrawCrossHair(new Vector2(_wayPoints[mouseNearCpNumber].X, _wayPoints[mouseNearCpNumber].Y), 15, col);
            }

            var p = new Vector2(positionWeightAtCycledTime.X, positionWeightAtCycledTime.Y);

            DrawHelpers.DrawCrossHair(p, 5, Color.White);
            _spriteBatch.DrawString(_font, $" pos X:{p.X.ToString("###0.00")}, Y:{p.Y.ToString("###0.00")}\n weight: {positionWeightAtCycledTime.W.ToString("####0.000")}", p + new Vector2(0, 20), Color.White);

            _spriteBatch.DrawString(_font, msg, new Vector2(10, 5), Color.White);

            _spriteBatch.End();

            base.Draw(gameTime);
        }
Example #2
0
        protected override void Draw(GameTime gameTime)
        {
            this.GraphicsDevice.Clear(Color.CornflowerBlue);

            _spriteBatch.Begin();
            curve.DrawWithSpriteBatch(_spriteBatch, _font, gameTime);
            DrawHelpers.DrawCrossHair(positionAtCycledTime.ToVector2(), 5, Color.White);
            _spriteBatch.DrawString(_font, msg, new Vector2(10, 5), Color.White);
            _spriteBatch.End();

            base.Draw(gameTime);
        }