Toggle menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Aliases: logJson

Arguments Returns
string... string

Displays any amount of arguments without separators or the [lua] prefix. The return value is the displayed text without the formatting. If an argument is a string, it is interpreted as a JSON text component, or if that fails, the string is displayed directly. All other types are displayed using tostring.

Example

-- Displays "Hello, world!" in green
printJson [[{"text": "Hello, world!", "color": "green"}]]
-- Displays the name of the avatar in gold (example of dynamic text)
printJson(toJson {
    text = avatar:getName(),
    color = "gold"
})

See also