OnServerStart: Difference between revisions

From Vice City Multiplayer
Jump to navigation Jump to search
Caution icon
This wiki is using an old backup from 2020
Some information may be old/missing
No edit summary
mNo edit summary
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
== Syntax ==
== Syntax ==
<pre>onServerStart()</pre>
<source lang=squirrel>
----
onServerStart()
== Arguments ==
</source>
 
* ''None''
----


== Example ==
== Example ==
The following example will print "Hello World!" when the server is started.
The following example will print "Hello World!" when the server is started.
<source lang=squirrel>
<source lang=squirrel>
function onServerStart()
function onServerStart() {
{
  print( "Hello World!" );
print( "Hello World!" );
}
}
</source>
</source>


== Notes ==
== Notes ==
Function print() was used in this example.The print() function outputs a formatted string on the console.
Function print() was used in this example.The print() function outputs a formatted string on the console.


== Related Functions ==
== Related Functions ==
{{Scripting/Squirrel/Events/Server_Events}}
{{Scripting/Squirrel/Events/Server_Events}}
[[Category:Scripting/Squirrel/Events/Server_Events]]
[[Category:Scripting/Squirrel/Events/Server_Events]]

Latest revision as of 21:08, 22 August 2019

Syntax

onServerStart()

Example

The following example will print "Hello World!" when the server is started.

function onServerStart() {
  print( "Hello World!" );
}

Notes

Function print() was used in this example.The print() function outputs a formatted string on the console.

Related Functions