Skip to main content

Rect(number x, number y, number width, number height)

Creates a new rectangle.

Parameters:

NameTypeDescription
xnumberThe X value the rect is measured from.
ynumberThe Y value the rect is measured from.
widthnumberThe width of the rectangle.
heightnumberThe height of the rectangle.

Usage

---@type number
local x;

---@type number
local y;

---@type number
local width;

---@type number
local height;


local rect = Rect(x, y, width, height);