From 8695476bebaea7469ea1aaf4c13ec8e020353d39 Mon Sep 17 00:00:00 2001 From: Diego Martinez Date: Mon, 19 May 2014 23:23:43 -0300 Subject: First commit. --- doc/API.md | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 doc/API.md (limited to 'doc/API.md') diff --git a/doc/API.md b/doc/API.md new file mode 100644 index 0000000..bee7c42 --- /dev/null +++ b/doc/API.md @@ -0,0 +1,32 @@ + +## Extended Ban Mod API + +### ban_player + +`xban.ban_player(player_or_ip, source, expires, reason)` + +Ban a player and all of his/her alternative names and IPs. + +#### Arguments: + +* `player_or_ip` - Player to search for and ban. See note 1 below. +* `source` - Source of the ban. See note 2 below. +* `expires` - Time at which the ban expires. If nil, ban is permanent. +* `reason` - Reason for ban. + +### unban_player + +`xban.unban_player(player_or_ip, source)` + +Unban a player and all of his/her alternative names and IPs. + +#### Arguments: + +* `player_or_ip` - Player to search for and unban. +* `source` - Source of the ban. See note 2 below. + +### Notes + +* 1: If player is currently online, all his accounts are kicked. +* 2: Mods using the xban API are advised to use the `"modname:source"` +format for `source` (for example: `"anticheat:main"`). -- cgit v1.2.3