DrawingImmediate.Text
Draws text.
Syntax
DrawingImmediate.Text(pos: Vector2, text: string, color: Color3, size?: any, font?: any) -> nil
Parameters
| Parameter | Type | Description |
|---|---|---|
pos | Vector2 | The pos value used by the call. |
text | string | The text value to process. |
color | Color3 | The color value used by the call. |
size? | any | The size of the object or buffer. |
font? | any | The font value used by the call. |
Returns
| Type | Description |
|---|---|
nil | This function does not return a value. |
Description
DrawingImmediate.Text is part of the DrawingImmediate library. Immediate drawing runs inside a paint callback registered with DrawingImmediate.GetPaint(); primitives are emitted for the current frame only.
The operation is performed immediately using the arguments supplied at the call site.
The aliases OutlinedText(pos, text, color, outlineColor?, size?) resolve to the same implementation.
Example
-- inside a DrawingImmediate.GetPaint():Connect callback
DrawingImmediate.Text(Vector2.new(20, 40), "Yuari", Color3.new(1, 1, 1), 18)
DrawingImmediate.OutlinedText(Vector2.new(20, 70), "Yuari", Color3.new(1, 1, 1), Color3.new(0, 0, 0), 18)
Notes
- Aliases:
OutlinedText(pos, text, color, outlineColor?, size?). - Draw calls must run inside a callback registered with DrawingImmediate.GetPaint().