1.3 KiB
1.3 KiB
Whitelist Docs
1. How it works
Whitelisted players and whitelist status are both saved into the mod storage, and they're updated every time one of the core functions below succeeds. The end (?)
2. Functions
2.1 Core
The
sender
field in here is optional. If specified, the sender will receive an output message
whitelist.enable(<sender>)
: enables the whitelistwhitelist.disable(<sender>)
: disables the whitelistwhitelist.add_player(p_name, <sender>)
: addsp_name
to the whitelist (not case sensitive)whitelist.remove_player(p_name, <sender>)
: removesp_name
from the whitelist (not case sensitive)
2.2 Utils
whitelist.print_list(sender)
: prints a message tosender
containing all the whitelisted playerswhitelist.is_player_whitelisted(p_name)
: returns whetherp_name
is whitelisted, as a boolean. If true, it also returns the name as it appears in the whitelist (as it's not case sensitive)whitelist.is_whitelist_enabled()
: returns whether the whitelist is enabled, as a boolean
3. About the author
I'm Zughy (Marco), a professional Italian pixel artist who fights for FOSS and digital ethics. If this mod spared you some time and you want to support me somehow, please consider donating on LiberaPay