atplayers
#
Operators, whitelist and banned players lists
Lists
#
Bases: enum.Enum
Players list type enum
PlayersList
#
Class for managing operators, whitelist and banned players lists
__init__(lst, atserv)
#
Class for managing operators, whitelist and banned players lists
Parameters:
Name | Type | Description | Default |
---|---|---|---|
lst |
Union[str, Lists]
|
Players list type, must be atplayers.Lists enum value |
required |
atserv |
python_aternos.atserver.AternosServer
|
atserver.AternosServer instance |
required |
add(name)
#
Appends a player to the list by the nickname
Parameters:
Name | Type | Description | Default |
---|---|---|---|
name |
str
|
Player's nickname |
required |
list_players(cache=True)
#
Parse a players list
Parameters:
Name | Type | Description | Default |
---|---|---|---|
cache |
bool
|
If the function should return cached list (highly recommended) |
True
|
Returns:
Type | Description |
---|---|
List[str]
|
List of players' nicknames |
remove(name)
#
Removes a player from the list by the nickname
Parameters:
Name | Type | Description | Default |
---|---|---|---|
name |
str
|
Player's nickname |
required |