What does it do?
This plug-in by default restricts players access to the spectator option and only grants access a player to spectator if they are either a root admin or have the reserved flag.
Also this now should work for the following mods:
- Counter Strike Source
- Day of Defeat Source
- Half Life 2 Multiplayer
- Insurgency Mod
- Team Fortress 2
If they are not root or do not have the reserved flag there are three things that could happen:
If the player already had a team and try switching
They get moved back to the team they came from
If didn't have a team (just joined), then two there are two options:
set to 1
The player will be moved to the team with the least amount of players
set to 2
The player will be moved to the team that is losing
In addition to the default method of restricting players, I added another two options which can be set via sm_resteams_team
By default it restricts the spectators (team 1), however if you were to set this to 2, then it would restrict the access to Terrorists and if set to 3, then it will restrict access to Counter Terrorists (or what ever the team name is in the mod you are using).
I want spectator access for myself, an army of "core admins" and our sponsors, but to disable it for the battalion of n00blets we have. This plugin will hopefully fulfil my and possibly your requirements, as it will be quite flexible by the time I've finished with it.
I will be adding another mode to this plug-in so that it will let normal admins swap teams (a Team/Clan restriction), this is primarily for us to run "Fight Nights" on our main server, where its the n00b army AKA Team MX take on the regulars in some hardcore "n00b on n00b" action and I don't have to keep moving non members off the team and can concentrate on getting killed in style.
- Default: 1 (enabled)
Enables the restriction of team joining, spectators by default
- Default: 1 (spectators)
Team to Restrict - Spectators = 1 (default), Terrorists = 2, Counter Terrorist = 3
- Default: 1 (player count)
Spectators swapping by: 1 = Player Count(default), 2 = Team Score
- Def: buttons/weapon_cant_buy.wav
Sound to play when player is denied access to a team
Pop the compiled smx file into your <%MOD DIR%>/addons/sourcemod/plugins
folder, change maps and enjoy.
You will need mp_allowspectators
set to 1 in your server.cfg file.
- DONE In V1.5:
Will look at TF2 later and see if its possible
- Will be adding a 'clan' mode, so that only clan members can swap teams (coming soon)
- First Release
- Lifted pRED*
's method of dealing with multiple mods and this plugin should now support most mods.
Special Thanks To:
- For my n00b questions at some silly time of the morning
- rount_start eh?