예제 #1
0
        public override void Draw(SpriteBatch spriteBatch)
        {
            if (visible)
            {
                txt.Draw(spriteBatch);
                btn.Draw(spriteBatch);

                if (btn.pressed)
                {
                    DrawRect(spriteBatch, rectOld, Color.Red * 0.5f);

                    if (!isPosSet)
                    {
                        //DrawM.Sprite.DrawLine(spriteBatch, p, 4, Color.Red, depth + 0.001f);
                        Vector2 g = customGrid();
                        Vector2 p = (Vector2.Transform(Input.mbPos, Matrix.Invert(viewTransform())) / g).RoundVector() * g;
                        DrawCross(spriteBatch, p, Color.Red * 0.5f);
                    }
                    else
                    {
                        DrawRect(spriteBatch, rect, Color.Red);
                    }
                }

                DrawEnd(spriteBatch);
            }
        }
예제 #2
0
        public override void Draw(SpriteBatch spriteBatch)
        {
            if (visible)
            {
                btn.Draw(spriteBatch);
                txt.Draw(spriteBatch);

                DrawEnd(spriteBatch);
            }
        }
예제 #3
0
        public override void Draw(SpriteBatch spriteBatch)
        {
            if (visible)
            {
                btn_Text.Draw(spriteBatch);
                btn_Arrow.Draw(spriteBatch);

                if (btn_Arrow.pressed)
                {
                    for (int i = 0; i < btn_Enums.Count; i++)
                    {
                        btn_Enums[i].Draw(spriteBatch);
                    }
                }

                DrawEnd(spriteBatch);
            }
        }