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); }
} // 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)
internal override void Draw() { base.Draw(); Color col = Color.FromNonPremultiplied(new Vector4(Vector3.One, CompositeAlpha)); backgroundImage.RenderOnScreen(0, 0, col); }
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))); } }
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); } }
internal override void Draw() { base.Draw(); minimapTex.RenderOnScreen(X, Y); }