hudRenderer.drawRect

Call Signature

drawRect(x, y, w, h, radius, color): void

Draws a rounded rectangle with a uniform corner radius and a solid color.

Parameters

x

number

The x position.

y

number

The y position.

w

number

The width.

h

number

The height.

radius

number

The corner radius.

color

Color

The fill color.

Returns

void

Call Signature

drawRect(x, y, w, h, rtl, rtr, rbr, rbl, color): void

Draws a rounded rectangle with per-corner radii (TL, TR, BR, BL) and a solid color.

Parameters

x

number

The x position.

y

number

The y position.

w

number

The width.

h

number

The height.

rtl

number

Top-left radius.

rtr

number

Top-right radius.

rbr

number

Bottom-right radius.

rbl

number

Bottom-left radius.

color

Color

The fill color.

Returns

void

Last updated