messagebox
Shows a native message box and returns its result.
Syntax
messagebox(text: string, caption: string, flags?: string) -> number
Parameters
| Parameter | Type | Description |
|---|---|---|
text | string | The text value to process. |
caption | string | The caption value used by the call. |
flags? | string | The flags value used by the call. |
Returns
| Type | Description |
|---|---|
number | Its result |
Description
messagebox is part of the Input library. Input helpers either read the current OS input state or synthesize OS-level events. Some game interactions also require the Roblox window to be focused.
The operation is performed immediately using the arguments supplied at the call site.
Example
local result = messagebox("Continue?", "Yuari", 4)
print(result)
Notes
- Synthetic input may be ignored by games that validate input origins.