|
Setting up Admins
You can either use MySQL or a File to store the admin accounts.
MySQL is faster and easier to handle if you have more than one server but you may not have access
to a MySQL database.
This document is for installing admins in a flat file. To use MySQL,
click here.
Open /addons/amxx/configs/users.ini
Add new admins with this formula:
| "name|ip|steamid" "password" "access flags" "account flags" |
For Steam, you do not have to set a password for your clients when using IP or
SteamID authentication.
If you DO set a password then you have to add this to the client's
autoexec.cfg, which is in their mod folder (create one if not):
setinfo <password field> "password"
example:
setinfo _pw "mypw" |
<password field> is the value of amx_password_field (set in
amx.cfg)
An example line for a Steam user to authenticate with full access and no
password (passwords are not necessary for steam):
| "STEAM_ID:0:1:3412347" "" "abcdefghijklmnopqrstu" "ce" |
|
Access flags:
| Flag |
Access |
Description |
| a |
ADMIN_IMMUNITY |
immunity (can't be kicked/baned/slayed/slaped and affected by other commmands) |
| b |
ADMIN_RESERVATION |
reservation (can join on reserved slots) |
| c |
ADMIN_KICK |
amx_kick command |
| d |
ADMIN_BAN |
amx_ban and amx_unban commands |
| e |
ADMIN_SLAY |
amx_slay and amx_slap commands |
| f |
ADMIN_MAP |
amx_map command |
| g |
ADMIN_CVAR |
amx_cvar command (not all cvars will be available) |
| h |
ADMIN_CFG |
amx_cfg command |
| i |
ADMIN_CHAT |
amx_chat and other chat commands |
| j |
ADMIN_VOTE |
amx_vote and other vote commands |
| k |
ADMIN_PASSWORD |
access to sv_password cvar (by amx_cvar command) |
| l |
ADMIN_RCON |
access to amx_rcon command and rcon_password cvar (by amx_cvar command) |
| m |
ADMIN_LEVEL_A |
custom level A (for additional plugins) |
| n |
ADMIN_LEVEL_B |
custom level B |
| o |
ADMIN_LEVEL_C |
custom level C |
| p |
ADMIN_LEVEL_D |
custom level D |
| q |
ADMIN_LEVEL_E |
custom level E |
| r |
ADMIN_LEVEL_F |
custom level F |
| s |
ADMIN_LEVEL_G |
custom level G |
| t |
ADMIN_LEVEL_H |
custom level H |
| u |
ADMIN_MENU |
menu access |
| z |
ADMIN_USER |
user (no access) |
|
Account flags:
| Flag |
Description |
| a |
disconnect player on invalid password |
| b |
clan tag |
| c |
this is steamid |
| d |
this is ip |
| e |
password is not checked (only name/ip/steamid needed) |
|
Setting up MySQL Admins
If you need to set up the MySQL module,
click here.
Open your "addons/amxx/plugins.ini" file and change:
admin.amx ; admin base (required
for any admin-related)
;admin_mysql.amx ; admin base - MySQL version (comment admin.amx) |
to:
;admin.amx ; admin base (required
for any admin-related)
admin_mysql.amx ; admin base - MySQL version (comment admin.amx) |
Then restart your server. Use phpMyAdmin to add admins, using the same
formula as above. Each column of the admin table corresponds to one of
the four parameters.
|