Set3DTextText
Jump to navigation
Jump to search
set3DTextText
Changes the text of a replicated world-space label owned by the current resource.
Syntax
bool set3DTextText(string textId, string text)
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
textId |
string |
yes | The opaque identifier returned by create3DText. |
text |
string |
yes | New valid UTF-8 text containing 1-128 characters and at most 256 bytes. |
Returns
Returns true when the label is owned by the current resource and the update is accepted; otherwise returns false.
Examples
Update a counter displayed in the world:
set3DTextText(counterLabel, "Ore delivered: " .. tostring(amount))
Notes
- Available only in server-side resource scripts.
- The accepted update is replicated reliably to every connected player.