Skip to content

How to add an admin to a CS 1.6 server with users.ini

One line in users.ini makes a player an admin. Use their SteamID and the "ce" account flags, then reload admins. Includes the full flags table.

Audience
New to running a server
Last checked
Steps
5
Reading time
4 min
On Hostsrc
Includes the steps for a Hostsrc server

To make a player an admin, add one line to cstrike/addons/amxmodx/configs/users.ini with their SteamID, an empty password, their access flags and the account flags ce. Then type amx_reloadadmins in the server console, or change the map.

cstrike/addons/amxmodx/configs/users.ini
"STEAM_0:1:23456789" "" "abcdefghijklmnopqrstu" "ce"

That line gives full admin rights to the player with that SteamID. c says the first field is a SteamID, and e says no password is checked.

On Hostsrc

AMX Mod X is part of the base pack on every new server, so users.ini is already there.

Before you start

  • The player's SteamID, or their name and a password you agree on.
  • A way to edit your server's files. In the control panel, open Files in your server's menu.
  • Access to the server console. In the control panel, open Console.

Steps

  1. Step 1: Find the player's SteamID

    Ask the player to join your server and type status in their game console. The line with their name shows a SteamID that starts with STEAM_0:. You can type status in the server console too and copy it from there.

    Console
    status
  2. Step 2: Open users.ini

    Open cstrike/addons/amxmodx/configs/users.ini. The top of the file explains every flag, and your admins go at the bottom. In Files, click the file name to open it in the editor.

    Leave the existing "loopback" line in place. It only applies to a server run from the game itself.

    File search for users.ini with the result highlighted

    Panel as of

  3. Step 3: Add the admin's line

    Add one line per admin at the end of the file. Each line has four fields, each in double quotes: who the admin is, the password, the access flags and the account flags.

    Choose access flags for what the admin should do. The full set abcdefghijklmnopqrstu is for the owner and trusted co-owners. A moderator who can use a reserved slot, kick, ban, slay, change the map, use admin chat and votes, and open the menu needs bcdefiju. The Access flags table below lists every letter.

    cstrike/addons/amxmodx/configs/users.ini
    ; Owner, by SteamID"STEAM_0:1:23456789" "" "abcdefghijklmnopqrstu" "ce" ; Moderator, by SteamID"STEAM_0:0:98765432" "" "bcdefiju" "ce"

    Note

    Never give an admin the z flag. It means "user, not an admin".

  4. Step 4: Save the file and reload the admins

    Save users.ini. In the editor, press Save Content. Then reload the admin list from the server console, or change the map.

    Console
    amx_reloadadmins
    Server menu in the control panel with Console highlighted

    Panel as of

  5. Step 5: Check that it worked

    Ask the admin to reconnect and type amxmodmenu in their console. The admin menu opens when they have the u flag.

    The AMX Mod X log in cstrike/addons/amxmodx/logs/ also records a line with "became an admin" each time an admin joins.

Access flags

These are the third field. Combine as many letters as you need, in any order.

FlagGives access to
aImmunity: can't be kicked, banned, slain or slapped
bReserved slots
camx_kick
damx_ban and amx_unban
eamx_slay and amx_slap
famx_map
gamx_cvar (not every cvar)
hamx_cfg
iamx_chat and the other chat commands
jamx_vote and the other vote commands
ksv_password through amx_cvar
lamx_rcon and rcon_password through amx_cvar
m to tCustom levels A to H, used by other plugins
uAdmin menus
vTemporary bans only (newer AMX Mod X versions; check the top of your users.ini)
zUser, not an admin

Account flags

These are the fourth field.

FlagMeaning
aKick the player if the password is wrong
bThe first field is a clan tag
cThe first field is a SteamID
dThe first field is an IP address
eDon't check the password
kThe name or tag is case-sensitive

The three usual combinations are ce for a SteamID, de for an IP address and a for a name with a password.

cstrike/addons/amxmodx/configs/users.ini
; By IP address: only for a fixed IP"203.0.113.50" "" "bcdefiju" "de" ; By name and password"ExampleAdmin" "change-this-password" "bcdefiju" "a"

A name-and-password admin sets the password in their own game before connecting. The setting name is _pw unless your amxx.cfg changes amx_password_field.

Console
setinfo _pw "change-this-password"

Troubleshooting

The admin has no rights after joining

Check these in order:

  • The admins were reloaded. Run amx_reloadadmins in the server console, or change the map.
  • The line doesn't start with ;, and all four fields are in double quotes.
  • The SteamID matches status exactly, including the 0 or 1 after STEAM_0:.
  • The account flags include c for a SteamID or d for an IP address.

The admin is kicked with "invalid password"

The line uses the account flag a and the password didn't match. The name in the game must match the first field exactly. The admin must run setinfo _pw "their-password" before they connect, not after.

Someone else got admin by using the admin's name

The line is name-based with the flag e, so no password is checked. Switch that admin to their SteamID with ce, or give them a password and the flag a.

The admin can use some commands but not others

The access flags don't include that command's letter. Add the letter from the Access flags table and reload the admins. If it still fails, the command's level may be changed in cstrike/addons/amxmodx/configs/cmdaccess.ini.

amx_reloadadmins says "You have no access to that command"

You typed it in your game console without the h flag. Run it in the server console instead, where it always works, or give yourself h in users.ini and change the map once.