Skip to content

drawRectFilled

Draws a filled rectangle.

TIP

All drawing functions should be called within a render callback/loop.

Syntax

lua
Ham.drawRectFilled(rect, color, rounding, roundingCorners)

Parameters

NameTypeDescription
recttableRectangle {x, y, w, h} or {x=..., y=..., w=..., h=...}
colortableColor {r, g, b, a}
roundingfloatCorner rounding radius (optional, default 0)
roundingCornersintegerCorner flags (optional, default 0)

Example

lua
Ham.drawRectFilled({100, 100, 200, 100}, {0, 128, 255, 200}, 10, 0)

See Also

Released under the ISC License.