Server Help

ASSS Custom Projects - <py> Automated team picking

D1st0rt - Sun Aug 03, 2008 10:54 am
Post subject: <py> Automated team picking
Here's a python freqmanager module I wrote to take care of picking teams a lot faster than a host could normally do it. It also has the added advantage of making people stay on the team they were picked to.

Usage
I would advise locking the arena and sticking everyone in spec until picking is done. To start out you need to assign captains with /?capt <freq number>. There can only be one captain per team. Once captains have been assigned, use ?pick <freq number of captain with first pick> to start the picking and it will pretty much take care of itself from there. If you want to reassign a captain, pm a new player with /?capt <freq number> and they will replace the previous captain. You can change who is in turn to pick at any time with ?pick <freq number>, which can be useful if somebody leaves. To remove a player's picked status pm them with /?resetpick. When picking is finished, you can disable captains from picking people with a simple ?pick. Any new players that come in will be able to go on any frequency they want, but picked players will be restricted to the team they were picked to until you /?resetpick them or ?resetpick the entire arena. This is all explained in the command help entries as well.

Installation
Copy hs_picker.py to your asss/bin folder
Put the following in your default player groupdef:
Code: Show/Hide
privcmd_pick
cmd_capt
Put the following in your mod/host groupdef:
Code: Show/Hide
cmd_pick
privcmd_capt
cmd_resetpick
privcmd_resetpick

?insmod <py> hs_picker
?attmod hs_picker

Good to go! I have tested briefly in Hyperspace and didn't have problems, but let me know if you come across any.
All times are -5 GMT
View topic
Powered by phpBB 2.0 .0.11 © 2001 phpBB Group