FontRenderer
This page goes over about the FontRnederer object.
width(text): Number
width(text): Number
Argument | Type | Description |
---|---|---|
|
| Text to calculate the width of. |
Returns the text width.
height(): Number
height(): Number
Returns the font height.
draw(text, x, y, color): Undefined
draw(text, x, y, color): Undefined
drawCentered(text, x, y, color): Undefined
drawCentered(text, x, y, color): Undefined
drawWithShadow(text, x, y, color): Undefined
drawWithShadow(text, x, y, color): Undefined
drawCenteredWithShadow(text, x, y, color): Undefined
drawCenteredWithShadow(text, x, y, color): Undefined
Argument | Type | Description |
---|---|---|
|
| Text to draw. |
|
| X position of the string to draw. |
|
| Y position of the string to draw. |
|
| 4-element array with the RGBA color to use. Example: [255, 255, 255, 255] would translate to a white color. You are not required to provide the alpha. |
Renders a string. The function name speaks for itself.
Last updated