This plugin executes configs when there are either a certain amount of clients on, a certain event occurs, a certain round starts or when there are a certain amount of minutes left on the map. You can use this to disable alltalk above x clients, or to change the map
when the timelimit hits, etc. The configs of course go into the cfg
folder and the console variables are as follows:
(0/1, def 1)
Enable/disable executing configs. The plugin will keep counting the rounds and timeleft when it's disabled, but it will only actually execute the configs when it's enabled.
(0/1, def. 1)
Enable/disable including bots when counting number of clients. This will allow you to disable counting fake clients as normal clients.
(0/1, def. 1)
Enable/disable including spectators when counting number of clients. This will allow you to disable counting spectators as normal clients.
Server command to reload the configs from executeconfigs.txt.
To customize which configs get executed, put the attached executeconfigs.txt
in the configs
folder. It contains some examples of which I'll explain one here:
This means that for all maps, when there are 0 clients on, emptyserver.cfg will get executed after 10 seconds. The delay is for when someone joins within those 10 seconds, it will look for a config for when there is 1 client on, and if found it will execute that line. If it wasn't found it will continue to execute emptyserver.cfg, so if you're changing the map in emptyserver.cfg, make sure it will stop doing that by creating an empty config for clients:1.
I've tested this on TF2, I'm sure it works on others too but bug reports are always welcome
- Rewrote most of the code to allow for easier additions.
- Added support for map specific configs.
- Added sm_executeconfigs_reload.
- Fixed invalid timer handle errors.
- Removed a stray LogMessage.
- Small fix when counting number of clients.
- Fixed timer errors.
- Added sm_executeconfigs_include_spec.
- Does not execute the found config if it is the last config that was executed.