Squirrel/Server/Functions/Server/SetPassword
From Liberty Unleashed Wiki
(Difference between revisions)
(New page: __NOTOC__ This will change the password required to connect the server. == Syntax == <code>bool SetPassword( string pass )</code> == Arguments == * '''pass''' - The new password needed...) |
m (Squirrel/Functions/Server/SetPassword moved to Squirrel/Server/Functions/Server/SetPassword: Separating from clientside scripts) |
Revision as of 04:19, 14 November 2009
This will change the password required to connect the server.
Syntax
bool SetPassword( string pass )
Arguments
- pass - The new password needed to join the server
Example
This command will change the server password when a player types '/setpass ubersecret'.
function OnPlayerCommand( id, cmd, text ) { if ( cmd == "setpass" ) { SetPassword( text ); } }
Notes
The call OnPlayerCommand was also used in the example. More info about this in the corresponding page.