• AMX Guide Home
  • Step 1: Installing AMX
  • Step 2: Enabling AMX
  • Step 3: Configuring AMX
  • AMX by File:
    • amx.cfg
    • mysql.cfg
    • clcmds.ini
    • cmds.ini
    • configs.ini
    • cvars.ini
    • maps.ini
    • modules.ini
    • paths.ini
    • plugins.ini
    • speech.ini
    • users.ini
  • AMX by Topic:
    • Creating Admins
    • Commands Guide
    • Plugin Installation
    • Plugin Compiling
    • Module Setup
    • Menu Use
    • Language Setup
    • Language Install
    • Weapon Restriction
    • Stats Setup
    • Custom Map Configs
  • Misc. Resources
  • Credit
AMX Mod 2006 Setup Guide
Half-Life server administration

plugins.ini - Adding more plugins

The plugins.ini file in your addons\amx\config folder is the list of what plugins are run in your server. See below how to edit this file and add or remove plugins from your server. This is what the default plugins.ini looks like:


; AMX Mod plugins

; To disable any plugin, add a semi-colon ';' to the beginning of its line

; You can disable the Just-In-Time (JIT) compiler with the 'nojit' keyword:
; pluginname.amx nojit
; (read the docs for more details)

; To load admins from a MySQL db, open the amx/examples/source/default/admin.sma file
; and follow the instructions.


language.amx        ; language management
admin.amx           ; admin base (required for any admin-related)
admincmd.amx        ; basic admin console commands
adminhelp.amx       ; help command for admin console commands
adminslots.amx      ; slot reservation
menufront.amx       ; front-end for admin and custom menus
cmdmenu.amx         ; command menu (speech, settings)
mapsmenu.amx        ; maps menu (vote, changelevel)
plmenu.amx          ; players menu (kick, ban, client cmds.)
telemenu.amx        ; teleport menu (Fun Module required!)
adminvote.amx       ; vote commands
antiflood.amx       ; prevent clients from chat-flooding the server
adminchat.amx       ; console chat commands
scrollmsg.amx       ; displays a scrolling message
imessage.amx        ; displays information messages
nextmap.amx         ; displays next map in mapcycle
mapchooser.amx      ; allows to vote for next map
timeleft.amx        ; displays time left on map
mapconfig.amx       ; executes custom map configuration files
pausecfg.amx        ; allows to pause and unpause some plugins
statscfg.amx        ; allows to manage stats plugins via menu and commands
plugmod_manager.amx ; manages amx's modules.ini and plugins.ini

; Counter-Strike
; Note: you don't need to declare csstats.amx here (CSStats will load it)
ff_manager.amx      ; friendly-fire manager
restmenu.amx        ; restrict weapons menu for Counter-Strike
statsx.amx          ; stats on death or round end (CSStats Module required!)
miscstats.amx       ; bunch of events announcement for Counter-Strike
stats_logging.amx   ; weapons stats logging (CSStats Module required!)

; Add custom plugins below

About the JIT:

The Just-In-Time compiler has been introduced in AMX 0.9.9. It allows 10+ times faster plugin execution.

For the curious ones that would wonder how it works: your .sma plugins are compiled to .amx files with the sc compiler. The .amx files are Abstract Machine eXecutables: they contain bytecode (instructions that has to be interpreted). Before AMX Mod 0.9.9, the only way to run plugins was to interpret their bytecode constantly, and this was consuming much resources. Now thanks to the JIT, the .amx plugins are compiled at load time to instructions that can be sent directly to the processor, no longer needing the (slow) interpreter. Plugins run faster, and your server will no longer suffer high stress when you declare many.

By default, AMX Mod tries to load plugins with the JIT. You can control this thanks to the amx_usejit localinfo (add +localinfo amx_usejit value to the command launching your server).

There are three possible values for this localinfo:

  • never: the JIT will never be used, all plugins will be run the old way
  • config (default): the JIT will try to run all your plugins
    You can ask AMX not to run the JIT on a specific plugin by adding the nojit keyword right after its line in your plugins.ini file:
    myplugin.amx nojit ; This is my plugin, I don't want the JIT for it
  • always: AMX will try to run all your plugins with the JIT, ignoring the nojit keywords you could have specified in your plugins.ini

Anyway, if the JIT compiler fails for some reason on a plugin, that one will be executed the old way.

Now there are two ways you can add plugins to your server:

Download pre-compiled plugins:

Then copy the .amx file to your addons\amx\plugins folder and add the line for that plugin to your plugins.ini file. Here are a few reasons this is not the best way:

  • The compiled plugin needs to be compiled to your version of AMX or it may not work.
  • When you upgrade AMX you should recompile all your plugins anyway.
  • You should know how to compile plugins, it's very easy and many edits can be made by non programmers such as myself.
  • You'll never know if someone decides to be hax0rish and gives you a plugin with malicious code in it.

Download the source and compile it:

(Click here to learn how to compile!)

Then copy the .amx file to your addons\amx\plugins folder and add the line for that plugin to your plugins.ini file. Here are a few reasons this is the best way:

  • You can edit the level of access to your choosing.
  • Many other people have seen the code and may have offered improvements and can see if the plugin is malicious.
  • It lets you learn a little bit more about the overall scheme of how AMX works. And that may come in handy.

Actually doing it:

There are literally hundreds of plugins that can be downloaded and installed into AMX to make it do many things. Here are a couple places to go and get more plugins:

  • The official AMX Mod plugins page
  • Newly released plugins forum

So go to one of those two links and find a plugin that you must have. It's a good idea just to do one plugin at first, this way if you have trouble it will be easier to find the point at which the problem occurred. Let's say you have a plugin called amx_gag.amx. This is what it would look like if it was in the plugins.ini file.

; Add custom plugins below
amx_gag.amx       ; admin gag (admins can gag players)

I started a new section for any plugins that I added and left the default plugin section alone. Now to test and see if the plugin you added is installed and running, start up your server. In the server's console type amx plugins. You should get something like this:

Currently loaded plugins:
      name              version  author     file             status    jit
[  1] Language Manager  2006.1   AMX Team   language.amx     running   yes
[  2] Admin Base        2006.1   AMX Team   admin.amx        running   yes
[  3] Admin Commands    2006.1   AMX Team   admincmd.amx     running   yes
[  4] Admin Help        2006.1   AMX Team   adminhelp.amx    running   yes

(etc, etc. Not all plugins shown)

[ 24] Admin gag         0.6      default    amx_gag.amx      running   yes

Troubleshooting:

If you see something like bad load under status or unknown under name while doing amx plugins, or [AMX] Plugin file open error (plugin "some_plugin.amx") while your server was starting up then possibly:

  • the plugin wasn't copied to the addons\amx\plugins folder
  • the name of the plugin doesn't match what you typed in the plugins.ini file.

AMX can also display [AMX] Function not found (name "some_function") (plugin "some_plugin.amx") at startup, then the problem is that the plugin requires a certain AMX Mod module to be loaded.

Half-Life is a registered trademark of VALVe Software and Sierra
AMX Mod was created by OLO and is not affiliated with VALVe.