ETPro:Pluggable Config Files
From WolfWiki
ETPro supports Pluggable Config Files. These files provide servers the use of additional features not available from traditional .cfg files.
Contents
Creation and Installation
Config files must be located in etpro/configs and their names must end in .config
Config file format
The following shows the .config syntax. This is not a complete config, the ... indicates that in a real config many similar commands would follow
configname "^/foobar^f 6v6" // config for 6v6 foobar league version 1.2.3.4 foobar6v6.version.foobarleague.com init { setl sv_pure 1 setl sv_cheats 0 setl g_gametype 3 ... command "pb_sv_enable" command "pb_sv_kicklen 1" command "pb_sv_cvarempty" ... } map default { set g_userTimeLimit 0 setl g_useralliedrespawntime 0 setl g_useraxisrespawntime 0 setl b_moverscale 1 } map radar { set g_userTimeLimit 12 command "forcecvar r_drawfoliage 0" } ... signature deadbeefdeadbeefdeadbeefdeadbeefdeadbeef
Config file details
- comments
- any text following // is a comment and is ignored
- version w.x.y.z some.dns.name
- ET will check that version matches the IP returned form some.dns.name If it does, ETPro displays the message "config is latest version available" to all players in warmup. not fully implemented - etpro doesn't currently do the DNS check.
- configname <name>
- defines the name of the config. This name is displayed to players in warmup, but is not used to refer to the config in config related commands. The name may contain ET Color Codes
- init
- The init block is executed only once, when the config is loaded by referee or rcon/console. It is never reloaded.
- map <mapname>|default
- The map blocks are loaded on every map_restart. The parameter is the mapname to match to. A parameter of default will execute that block for all maps. map blocks are executed in order from first to last. Generally you want your default block first, and then specific map blocks to override it.
- signature <sig>
- provides crypotgraphic signature to verify that that the config is unmodified. ETPro displays the message "config is certified" to all players in warmup. The signature must be generated by the etpro team.
init and map are followed by a block, delimited by curly braces {}. Each block can contain the following keywords
- set <cvarname> "value"
- sets the specified cvar to the specified value.
- setl <cvarname> "value"
- sets the specified cvar to the specified value, and locks it so that it cannot be changed by rcon, forcecvar or other means until the config is unloaded
- command "command text"
- execute "command text"
- callvote | ref config <config file name>
- set the current config by vote or ref.
- config <config file name>|none
- set the current config from the server console, or unload the current config. Settings set by the config remain in effect, but are no longer locked. Map specific blocks are no longer in effect.
notes:
- config none can only be done from the console (or rcon) not by ref or vote.
- you must use the filename of the .config (minus the .config extension), not the 'configname' contained in the .config file. The 'configname' is a longer (possibly colored etc) descriptive name.
Getting your config Certified
Talk to one of the ETPro Developers on IRC
See also
- Cvar Restrictions
- Forced Cvars
- WolfWiki:Community_Portal#Leagues / Competitions is a good place to find full config file examples.