This wiki was in read-only mode for many years, but can now be edited again. A lot of information will need to be updated.
Bz HostBanUser: Difference between revisions
		
		
		
		Jump to navigation
		Jump to search
		
 Create API Function Page. Include Example.  | 
			
(No difference) 
 | 
Latest revision as of 08:30, 19 October 2011
bool bz_HostBanUser (int bannedByIndex, const char* hostmask, int duration, const char* reason)
Sets up a new Host ban Rule in the ban list.
Parameters: 
bannedByIndex  -  The player ID that is banning the IP Address. NOTE: This has to be a player that is currently on the server, so at least one player must be present for a ban to be created. 
hostmask  -  The Hosting address of the player to be banned. Host bans use wildcard (*) character also, such as *.myhost.biz 
duration  -  The amount of time in minutes to ban the host. 
reason  -  The reason that is displayed to the banned user upon failure to join. 
Returns: 
Whether or not the ban was executed successfully.
Example
bz_HostBanUser(0,"*.myhost.biz",3600,"This host abused the server.")