warn
Writes a warning line to the Output panel.
warn joins its arguments the same way print does, then puts Warn: in front of the line. The prefix is part of the message text, so it still shows up in logs that cannot color the output.
Signature
| Call | Returns |
|---|---|
warn(...) |
nothing |
Example
local target = workspace:FindFirstChild("Door")
if not target then
warn("Door is missing from the workspace")
end
The Output panel shows Warn: Door is missing from the workspace.
See also
- print: the plain output call.
- Troubleshooting: what to do with the errors you find.
- API Reference