TextLabel
A line of 3D text your gamemode put in the world with textLabels.create, as
textLabels.listAll, textLabels.getById and the scriptMarkerCreated events
give it. It does not change; read it again for a newer one.
Renamed in 0.28 from Label and LabelSettings; see renamed names.
Definition
Section titled “Definition”type TextLabel = Readonly<{ markerKind: "textLabel"; id: number; text: string; position: Vector3; colorRgba: number; drawDistance: number; testLineOfSight: boolean; interior: number; virtualWorld: number; visible: boolean; players: readonly number[] | null;}>;
type TextLabelSettings = MarkerTargeting & { text: string; position: Vector3; colorRgba?: number; drawDistance?: number; testLineOfSight?: boolean;};Fields
Section titled “Fields”| Field | Type | Description |
|---|---|---|
markerKind |
"textLabel" |
Tells it apart from the other world markers. |
id |
number |
Its ID. |
text |
string |
The line it shows. |
position |
Vector3 |
Where it stands. |
colorRgba |
number |
Its color, 0xRRGGBBAA. |
drawDistance |
number |
How near a player must be to see it, in metres; 0 is the whole map. |
testLineOfSight |
boolean |
true: hidden behind buildings. |
interior, virtualWorld, visible, players |
Who sees it; see MarkerTargeting. players holds player IDs, or null for everyone. |
TextLabelSettings has the same fields, all but text and position optional; the defaults are on
textLabels.create.
Related
Section titled “Related”textLabels.create: make oneWorldMarker: text labels, map icons, checkpoints and areas- World markers