AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Snippets and Tutorials (https://forums.alliedmods.net/forumdisplay.php?f=112)
-   -   [TF2] PubComp - almost-finished tournament system (https://forums.alliedmods.net/showthread.php?t=193934)

Vincenator 08-23-2012 23:45

[TF2] PubComp - almost-finished tournament system
 
1 Attachment(s)
I wrote this plugin last summer for the PubComp matchmaking/lobby project, but since it doesn't look like anything is happening with it for the indefinite future I'm going to post my code here for anyone's reference.

This mod was built to run with a website (kinda like TF2Lobby) that would send it rcon commands once certain things happen on the website, like a full twelve players joining the game lobby. Its function is similar to ESEA's plugin, but it's more advanced.

The plugin has class/team limits, a warmup mod, the ability to have limited spectators, a whitelist kick feature, and a few other things. The class limits can also be specific to players - a player will be allowed through an rcon command to play only certain classes. The idea is that if you sign up to play a certain "role", like "support", and are limited to classes that fit that role to avoid griefing. If a player disconnects while the match is underway, the server will pause. If the player doesn't rejoin within a minute, the other players vote on whether to wait another minute for the player to rejoin or to unpause the game without them.

Example of how the system works:
The server changes to the right map. All the players' names are listed on the left of the screen as "Ready", "Not ready", or "Not Connected". Until enough players type ".ready", the server plays SOAP DM as a warmup. Once enough players type ".ready", the server forces everyone to the team and class they signed up for on the website, and it switches to tournament mode. The plugin logs some events and has some minor tweaks during the game, and when the game ends it switches back to the warmup mode.

http://s11.postimage.org/7hpij64ox/2_play.jpg

The attached zip has a readme file which thoroughly explains all the commands and features. Some of the most useful ones to copy-and-paste are the class/team limits and the automatic server pausing. If you're interested in any of its features at all, please look at the readme in the zip for a list of all the commands the plugin can do. There are a lot of useful functions in here - please use them if they will help you!

Thanks,
- Vincenator


All times are GMT -4. The time now is 16:18.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.