Scripting/Squirrel/Functions/Misc/UnbanIP

From VC-MP Wiki

Jump to: navigation, search

This function removes an IP address from the banlist.

Syntax

bool UnbanIP( string ip )

Arguments

  • ip - This is the IP address to be unbanned

Example

This example will unban the IP address player entered with the command '/c unbanip 127.0.0.1'.

function onPlayerCommand( player, cmd, text )
{
     if ( cmd == "unbanip" )
     {
          MessagePlayer( "You have unbanned IP " +text, player );
          UnbanIP( text );
     }
}

Notes

The function MessagePlayer and call onPlayerCommand were used in in this example. More info about them in the corresponding pages.

Related Functions

Personal tools
squirrel scripting