This is a Source port of my AMXX plugin JailMod++. It allows to put people in a jail on the map by stripping all weapons from them and teleporting them to a set of previously stored coordinates.
For each map, there can be up to five jails. The jail coordinates are configured using an admin menu, allowing to add or edit jails quite easily.
- jail <player>
Puts a player in jail.
- unjail <player>
Sets a player free.
Reloads the jail database (neccessary if you changed jails via the admin menu.)
- jail_strip <0|1>
If 0, Weapons are not stripped from players when they are put in jail (that way, you can re-use jails in surf maps, for example)
- jail_fill <0|1>
Changes the way jails are chosen, when a player is to be jailed.
If 0, a random jail is picked.
If 1, the first jail which has room left will be used.
- jail_tkpunish <0|1>
If 1, team killers will be jailed automatically.
This plugin uses a database to store the jail coordinates in, so you need to have a named database config "jailmod" or "default" for this to work. The table will be created automatically.
Attached, you will find a MySQL and SQLite database containing sample Jail coordinates for CS:Source.
I'm currently testing on various mods. It was developed with CS:Source, but there isn't any mod-specific code in there as far as I can tell, so it should work on any mod.
1.1: Bugfix - forgot to call GetClientOfUserId in events, that's why console got spammed with "Array index out of bounds" and TK punish didn't work...