Squirrel/Server/Events/Misc/onScriptUnload
From Liberty Unleashed Wiki
(Difference between revisions)
m |
|||
Line 29: | Line 29: | ||
=== Notes === | === Notes === | ||
− | The function [[Squirrel/Server/Functions/Misc/print|print]] was used | + | The function [[Squirrel/Server/Functions/Misc/print|print]] was used in this example. More info about this in the corresponding page. |
== Related Events == | == Related Events == | ||
{{Squirrel/Server/Events/Misc}} | {{Squirrel/Server/Events/Misc}} |
Latest revision as of 12:44, 11 November 2010
This function is called when a squirrel script is unloaded automatically by the server on shutdown, via manual console input or using the function UnloadScript. This event is only called in the script which was unloaded.
[edit] Syntax
function onScriptUnload()
[edit] Arguments
- none
[edit] Returns
This event does not handle return values.
[edit] Example
This example will print the name of the loaded script to the server console.
function onScriptUnload() { print( "Unloaded LU Test Script" ); return 1; }
[edit] Notes
The function print was used in this example. More info about this in the corresponding page.
[edit] Related Events
- onConsoleInput
- onScriptLoad
- onScriptUnload
- onServerStart