rconsoleerr Synchronous
consoleerrrconsoleerror
Mark a failed operation in the script console with an Error label. It gives the user a visible failure message without changing Luau control flow.
Luau
rconsoleerr(data: any, async: boolean?) -> ()Parameters
| Parameter | Type | Description |
|---|---|---|
data | any | Error value to stringify. |
async | boolean? | Optional compatibility boolean; validated but otherwise unused. |
Returns
()No values.
Usage notes
If the caller also needs to stop, raise an error separately.
Example
Luau
rconsoleshow()
local ok, result = pcall(function() return readfile("required-input.txt") end)
if not ok then rconsoleerr(result) end