OnScriptError: Difference between revisions

From Onset Developer Wiki
Chloe (talk | contribs)
mNo edit summary
No edit summary
Line 1: Line 1:
{{Info|Event|Client|1.0}}
{{Info|Event|Client & Server|1.0}}


{{FuncDescription|Called when a script error occurs. This is only called when the game was started with the '''-dev''' switch.}}
{{FuncDescription|Called when a script error occurs. This is only called when the game was started with the '''-dev''' switch.}}

Revision as of 20:27, 18 January 2020

OnScriptError

Type: Event
Context: Client & Server
Introduced: v1.0

Description

Called when a script error occurs. This is only called when the game was started with the -dev switch.

Syntax

OnScriptError(message)

Parameters

  • message
    The script error message.

Example

function OnScriptError(message)
	AddPlayerChat('<span color="#ff0000bb" style="bold" size="10">'..message..'</>')
end
AddEvent("OnScriptError", OnScriptError)

See also