Want to improve the docs? Take a look at scripting-api-data!
Found a bug? jc3mp/bugs is a good place to let us know.
This class currently lacks documentation for the constructor.
Name | Type | Description |
---|---|---|
viewportSize | Vector2f | read only |
dtf | number | read only |
Name | Type | Description |
---|---|---|
enabled | boolean | Enables or disables culling. |
Sets the matrix that describes the coordinate system the renderer is drawing to.
Name | Type | Description |
---|---|---|
matrix | Matrix | The new transformation 4x4 matrix |
Draws a text to the screen or world.
Name | Type | Description |
---|---|---|
text | string | The text you want to draw |
position | Vector3f | The position vector. Set the z-coordinate to 0.5 if you render to the screen. |
maxSize | Vector2f | Maximum size |
color | RGBA | Text color |
fontSize | number | Font size |
fontName | string | Font name (all Windows fonts are valid here) |
Returns the physical dimensions of a text.
returns: Vector2f
Name | Type | Description |
---|---|---|
text | string | Text |
fontSize | number | Font size |
fontName | string | Font name |
Draws a rectangle (behaves similarly to DrawText).
Name | Type | Description |
---|---|---|
position | [Vector3f, Vector2f] | Position |
size | Vector2f | Size |
color | RGBA | Text color |
Draws a rectangle (behaves similarly to DrawText).
Name | Type | Description |
---|---|---|
start | [Vector3f, Vector2f] | Start position |
end | [Vector3f, Vector2f] | End position |
color | RGBA | Text color |
Draws a texture object.
Name | Type | Description |
---|---|---|
texture | Texture | the Texture to draw |
position | [Vector3f, Vector2f] | Position |
size | Vector2f | Size |
returns: Vector2f
Name | Type | Description |
---|---|---|
p1 | Vector3f |
By becoming the newest member of our growing forums, we and hundreds of other players will always keep you up to date on everything JC3:MP related.