Squirrel/Server/Functions/Misc/BanPlayer
From Liberty Unleashed Wiki
(Difference between revisions)
(updated) |
m (minor fuckups) |
||
Line 4: | Line 4: | ||
== Syntax == | == Syntax == | ||
− | <code>bool BanPlayer( | + | <code>bool BanPlayer( Player plr )</code> |
== Arguments == | == Arguments == |
Revision as of 01:46, 27 November 2009
This function bans a player from the server.
Syntax
bool BanPlayer( Player plr )
Arguments
- plr - Pointer of the player to ban
Example
This will ban anybody called 'Bob'
function onPlayerJoin( player ) { if ( player.Name == "Bob" ) { MessagePlayer( "NO BOBS ALLOWED!", player ); BanPlayer( player ); } }
Notes
The functions Player.Name, MessagePlayer and call onPlayerJoin were used in in this example. More info about there in the corresponding pages.