Esempio n. 1
0
        internal override void Draw()
        {
            base.Draw();

            WWTexture background = null;

            if (isPressed)
            {
                background = backgroundClicked;
            }
            else
            {
                background = backgroundNotClicked;
            }

            if (background == null)
            {
                return;
            }

            Vector2 screenPos = ScreenPosition;

            Color col = Color.FromNonPremultiplied(new Vector4(Vector3.One, CompositeAlpha));

            background.RenderOnScreen(screenPos.X, screenPos.Y, Width, Height, col);

            colText.Render(screenPos.X, screenPos.Y, (float)Width, (float)Height, font, TextAlignHorizontal.Center, col, Color.Yellow);
        }
Esempio n. 2
0
        } // Tile(data)

        /// <summary>
        /// Render
        /// </summary>
        internal void Render(float x, float y, float scale)
        {
            texture.RenderOnScreen(x * scale, y * scale, 16.0f * scale, 16.0f * scale);
            if (DebugOptions.ShowTiles)
            {
                WWTexture.RenderRectangle(new RectangleF(x * scale, y * scale, 16.0f * scale, 16.0f * scale), Color.Red);
            }
        } // Render(x, y)
Esempio n. 3
0
        internal override void Draw()
        {
            base.Draw();

            Color col = Color.FromNonPremultiplied(new Vector4(Vector3.One, CompositeAlpha));

            backgroundImage.RenderOnScreen(0, 0, col);
        }
Esempio n. 4
0
        internal override void Draw()
        {
            base.Draw();

            if (image != null)
            {
                Vector2 screenPos = ScreenPosition;

                image.RenderOnScreen(screenPos.X, screenPos.Y, Width, Height, Color.FromNonPremultiplied(new Vector4(Vector3.One, CompositeAlpha)));
            }
        }
Esempio n. 5
0
        internal override void Draw()
        {
            base.Draw();

            if (Sprite == null)
            {
                return;
            }

            Vector2 screenPos = ScreenPosition;

            WWTexture image = Sprite.CurrentFrameTexture;

            if (image != null)
            {
                image.RenderOnScreen(screenPos.X, screenPos.Y, Width, Height);
            }
        }
Esempio n. 6
0
        internal override void Draw()
        {
            base.Draw();

            minimapTex.RenderOnScreen(X, Y);
        }