Thread: JailMod++
View Single Post
Plugin Info:     Modification:          Category:          Approver:   twistedeuphoria (82)
MistaGee
Senior Member
Join Date: Aug 2004
Location: Germany (Fulda)
Old 08-16-2005 , 08:04   JailMod++
Reply With Quote #1

I've grabbed the Idea of MyStIcSsJgOkU4 @ http://forums.alliedmods.net/showthread.php?t=16031 and wrote my own version of this script (from scratch) which has a bit more functionality than the original one.

There's the following CVars:
Code:
amx_jail_time
This is the default time ppl are sent to jail if none is given.
amx_jail_allow
Guess what..? :P this cvar is set automatically to 1|0 according to whether a jail was found for this map or not but can be changed of course.
amx_jail_returnweapons
Sets if ppl who are released from jail are returned their weapons.
amx_jail_godmode
this defines if the inmates are provided with godmode to not be able to get killed by other inmates / ppl who can shoot from the outside into the jail (like, on cs_militia).
Then there's a couple of commands:
Code:
amx_jail <name> [<-1|0|time>] [<jail #>]
Puts ppl into jail. If time is not specified or -1, the default value from the cvar is used. if time equals 0, the victim will be put into jail until round end.

amx_unjail <name> - use to get ppl out of jail
amx_readjail - use to read the coordinates file once again
amx_viewjail [jail #] - use to see who is in that jail / in all jails
amx_listjail - use to get a list of all jail coordinates
amx_jailmenu - use to get a menu with further options allowing you to config the whole script and save the config.
In the menu, you can delete jail coordinates, add new ones, and toggle noclip mode to reach the positions you want as jail &quot;spawnpoints&quot;.
In the Menu, you will be shown all the coordinates that have yet been set. Pressing the corresponding key deletes a set of coordinates, pressing key 6 will add the ones you are currently located at. Pressing 7 toggles noclip. Key 8 is for reading the config once again (which makes all your changes null and void), 9 writes the current data to the config file (saving your settings 4ever) and key 0 closes the menu, disabling noclip if enabled.

The default admin level is ADMIN_SLAY but can be changed by changing a #define in the sma. This one adminlevel is used for ALL commands.

This script is only tested on CS but should work on other mods as well.

Requirements:
- Amxx (how come )
- fun module for godmode & noclip

THX to:
MyStIcSsJgOkU4 for the basic idea
f117bomb & T(+)rget for amx_atac 5.2.3 from where I leadned how to strip weapons

Parts of the Idea, Coding & Testing by MistaGee

Enjoy!
Greetz MGee
Attached Files
File Type: txt jailmod.txt (2.7 KB, 4860 views)
File Type: txt jailmod_jails.txt (283 Bytes, 4258 views)
File Type: sma Get Plugin or Get Source (jailmod.sma - 8899 views - 21.6 KB)
__________________
Ich hab nie behauptet dass ich kein Genie bin!
Mumble-Django: A web interface for Mumble

Last edited by MistaGee; 11-15-2007 at 10:37.
MistaGee is offline
Send a message via ICQ to MistaGee