This plugin provides reserved
slots for admins (or better: reserved
connection slots) like in mani plugin.
The number of reserved
slots is given by sm_hreserved_slots_amount. If sm_hreserved_slots_amount is undefined or set to -1, the number of hidden slots given by the number of total slots minus content of variable sv_visiblemaxplayer will be treated as reserved
New for Version 2.0: If no reserved
slots are defined explicitely neither there are any hidden slots, the connect
extension is used, if available.
If the public slots are full, normal players will be rejected from connecting on the reserved
slot(s). When an admin with reserved
slot access joins and sm_hreserved_drop_method is set to "1",
a public slot is freed by kicking a non-admin. Afterwards the reserved
slot is free again for the next admin to join.
If sm_hreserved_use_immunity is set to 1, the plugin uses the sourcemod-immunity level assigned to the players/admins to select the player to be kicked. If players have different immunity-levels one of them with the lowest immunity-level goes first. If sm_hreserved_immunity_decrement is set to a value above 0 the immunity-level of spectators is decreased by the value of sm_hreserved_immunity_decrement to make him beeing kicked before the other members of their immunity level. Admins with reserved
slot access flag may be protected from beeing kicked by the setting of sm_hreserved_admin_protection.
sourcemod version 1.4.x
hrs_status: print a status screen with informations about the current players and their probability of beeing dropped accourding the plugins config. needs generic admin flag.
the configuration file hreserved_slots.cfg is located at <moddir>cfg/sourcemod/hreserved_slots.cfg. It will automatically be generated if missing. (So you do not really need to download and install this from the attachement). Additionally the plugin may use the externel cvar sv_visiblemaxplayers if you do not configure the amount of reserved slots explicitely.
- sm_hreserved_slots_enable: (def. "1") 0/1, disable/enable reserved slots
- sm_hreserved_slots_amount: <int>, (def. "-1") number of reserved slots. Do not specify or set to -1 to automatically use hidden slots as reserved. New for version 2.0: set to 0 to enforce the use of the connect extension.
- sv_visiblemaxplayers: <int>, set to the amount of public slots you wish to keep usable and visible to players. Set below the maximum number of slots your server provides. The difference between maximum slots and visible slots will become your reserved slots. May also be used in conjunction with sm_hreserved_slots_amount.
- sm_hreserved_admin_protection: (def. "1")
- 0 - admins are not protected from beeing dropped from server apart of their immunity level
- 1 - admins are protected from beeing kicked except they are in spectator mode
- 2 - admins will never be dropped from server to free reserved slots
- sm_hreserved_immunity_decrement: <int> (def. "1"), value to be subtracted from the immunity level of spectators. The value 0 will make spectators to be treated like players in the game.
- sm_hreserved_use_immunity: (def. "1")
- 0 - the player immunity level will not be used to find a player to be dropped (is assumed to be 0 for all players). However, admin protection as specified by sm_hreserved_admin_protection still keeps valid.
- 1 - use sourcemod immunity level to group players to priorities for beeing dropped from server
- sm_hreserved_drop_method: (def. "1")
- 0 - no players are dropped from server, reserved slot is blocked until a player leaves on his own,
- 1 - kick a player to free reserved slot. New for version 2.0: if the connect extension is used, this is the only available drop method
- 2 - offer player to be redirected to the server specified in sm_hreserved_redirect_target. If the player does not accept the redirection he will be kicked.
- sm_hreserved_redirect_target: (def. ""), alternate server a client is offered to be redirected to if sm_hreserved_drop_method is set to value 2.
- sm_hreserved_redirect_timer: (def. "12"), time to show the redirection offer dialog.
- sm_hreserved_drop_select: (def. "0"), select how players are chosen to be dropped from server when there are multiple targets with the same priority.
- 0 - Drop player with highest ping
- 1 - Drop player with shortest connection time
- 2 - Drop random target
- sm_hreserved_bot_protection: (def. "0")
- 0 - bots/fake clients will be kicked to free slots
- 1 - bots/fake clients (e.g. SourceTV) will not be kicked to free reserved slots
- sm_hreserved_auth_by_tag: (def. "0"), use clan tag given by variable sm_hreserved_auth_tag for admin authentication (mostly not very reasonable until protecting clan tags by external plugin)
- sm_hreserved_auth_tag: (def. ""), clan tag given used for admin authentication (needs sm_hreserved_auth_by_tag=1)
2.0: integrated connect extension; handling teamless players like spectators (thx to Corvette911); cleaned up debug output
1.5: reservations based on name tags
1.4.1: added some logging
1.4: added random target (sm_hreserved_drop_select 2)
1.3.1-r3: bugfix to avoid redirects on fake clients
1.3.1-r1: adaption to changed sourcemod behavior (UPDATE STRONGLY RECOMMENDED IF USING SOURCEMOD RELEASE >= 1854)
1.3.1: added center message on redirection
1.3: added config file hreserved_slots.cfg
1.2.3: fixed bug on hooking on cvar sm_hreserved_slots_enable causing the same player to be selected for dropping multiple times
1.2.2: changed GetClientCount(false) to GetClientCount(true); ?maybe? this did lead to unspecified behaviour for some configs
1.2.1: minor change for estimation of curently connected players (just to make the code more clear; no functional change); extended hrs_status screen
1.2: removed redundant call on debug-output; added cvar sm_hreserved_bot_protection; made hrs_status an official command (cleaned up output & restricted access to admins with generic admin flag); hooking on cvar sm_hreserved_slots_enable to make slots to be freed if plugin is enabled at runtime
1.1: added client redirection option as an alternative for kicking; major code cleanups; removed depecated cvar sm_hidden_slots_reserved
1.0.8: added option sm_hreserved_drop_select
1.0.7: added custom options sm_hreserved_admin_protection, sm_hreserved_immunity_decrement, sm_hreserved_use_immunity, sm_hreserved_drop_method
1.0.6: added sm_hreserved_slots_amount, changed enable variable from sm_hidden_slots_reserved to sm_hreserved_slots_enable (old name was inappropriate for new function with visible reserved slots)
1.0.5 beta: first public release