RectIntclass
Represents a rectangle but with whole numbers
Constructors2
Showing 2 constructors
No results match this filter.
Methods12
Showing 12 methods
public Sandbox.RectInt AddPoint(Vector2Int pos)
Returns this rect expanded to include this point
| Parameter | Type | Description |
|---|---|---|
| pos | Vector2Int | — |
public static Sandbox.RectInt FromPoints(Vector2Int a, Vector2Int b)
Create a rect between two points. The order of the points doesn't matter.
| Parameter | Type | Description |
|---|---|---|
| a | Vector2Int | — |
| b | Vector2Int | — |
No results match this filter.
Properties14
Showing 14 properties
public int Sandbox.RectInt.Bottom { get; set; }
Position of rect's bottom edge relative to its parent.
int—public Vector2Int Sandbox.RectInt.BottomLeft { get; set; }
Position of the bottom left edge of this rect.
public Vector2Int Sandbox.RectInt.BottomRight { get; set; }
Position of the bottom right edge of this rect.
public int Sandbox.RectInt.Height { get; set; }
Height of the rect.
int—public int Sandbox.RectInt.Left { get; set; }
Position of rect's left edge relative to its parent, can also be interpreted as its position on the X axis.
int—public Vector2Int Sandbox.RectInt.Position { get; set; }
Position of this rect.
public int Sandbox.RectInt.Right { get; set; }
Position of rect's right edge relative to its parent.
int—public Vector2Int Sandbox.RectInt.Size { get; set; }
Size of this rect.
public int Sandbox.RectInt.Top { get; set; }
Position of rect's top edge relative to its parent, can also be interpreted as its position on the Y axis.
int—public Vector2Int Sandbox.RectInt.TopLeft { get; set; }
Position of the top left edge of this rect.
public Vector2Int Sandbox.RectInt.TopRight { get; set; }
Position of the top right edge of this rect.
public int Sandbox.RectInt.Width { get; set; }
Width of the rect.
int—No results match this filter.