Class RectElement
Simple rectangle element
Inherited Members
Namespace: Genesis.Core.GameElements
Assembly: Genesis.dll
Syntax
public class RectElement : GameElement
Constructors
RectElement(string, Vec3, Vec3)
Creates a new rectangle
Declaration
public RectElement(string name, Vec3 location, Vec3 size)
Parameters
Type | Name | Description |
---|---|---|
string | name | The name of the rectangle. |
Vec3 | location | The location of the rectangle. |
Vec3 | size | The size of the rectangle. |
Properties
BorderColor
Gets or sets the color of the rectangle border.
Declaration
public Color BorderColor { get; set; }
Property Value
Type | Description |
---|---|
Color |
BorderWidth
Gets or sets the width of the rectangle border.
Declaration
public float BorderWidth { get; set; }
Property Value
Type | Description |
---|---|
float |
Fill
Gets or sets the fill color of the rectangle.
Declaration
public Color Fill { get; set; }
Property Value
Type | Description |
---|---|
Color |
HasBorder
Gets or sets a value indicating whether the rectangle has a border.
Declaration
public bool HasBorder { get; set; }
Property Value
Type | Description |
---|---|
bool |
HasFill
Gets or sets a value indicating whether the rectangle has fill color.
Declaration
public bool HasFill { get; set; }
Property Value
Type | Description |
---|---|
bool |
Methods
OnRender(Game, IRenderDevice)
Renders the rectangle
Declaration
public override void OnRender(Game game, IRenderDevice renderDevice)
Parameters
Type | Name | Description |
---|---|---|
Game | game | The game instance. |
IRenderDevice | renderDevice | The render device used for rendering. |