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 eAllowPlayer
| BZFS API Documentation This page contains part of the BZFS API documentation for use by Plug-ins on the BZFS server. |
BZFS Event. This page documents a BZFS event that is called by the game server to notify plug-ins of various actions and state changes in the game world.
Overview
The bz_eAllowPlayer is an API event that is called each time a player joins to allow a plug-in to override the servers allow or deny choice.
Data
bz_eAllowPlayer returns the bz_AllowPlayerEventData_V1 data class.
| name | type | value description |
|---|---|---|
| eventType | bz_eEventType | bz_eAllowPlayer |
| playerID | int | Each client has a player ID, even if that client is not yet in the game yet. This way, every client can be identified using an integer value. |
| callsign | bz_ApiString | The player's callsign |
| ipAddress | bz_ApiString | The IP address of the client which is trying to get into the game |
| reason | bz_ApiString | If a plugin denies the entrance of a player, then that plugin can explain why in this field. |
| allow | bool | This value should be set to true by the plugin if that plugin decided to allow the player to enter the game, and false otherwise. |
| eventTime | double | This value is the time at which the client requested to enter the game (and thus the event was created). |
Uses
A plugin can use this event to use an alternative to a ban list to decide whether a user should be allowed to play on the server. For example, if the server load is temporarily high, then a plugin could deny the entrance of even more users temporarily.
