Raised This Month: $12 Target: $400
 3% 

Immunity Reserve Slots (2.0.8)


Post New Thread Reply   
 
Thread Tools Display Modes
Author
Jamster
Veteran Member
Join Date: Jun 2008
Plugin ID:
890
Plugin Version:
2.0.8
Plugin Category:
Server Management
Plugin Game:
Any
Plugin Dependencies:
    Servers with this Plugin:
    13 
    Plugin Description:
    Immunity based reserve slots for CBaseServer Tools and Connect extensions
    Old 05-23-2009 , 18:23   Immunity Reserve Slots (2.0.8)
    Reply With Quote #1

    How to connect to a server using reserve slots
    To use reserve slots when a server is full you and your users need to type into the console: connect <ip address>:<port> (port not needed if you're running on the default port for whatever server you run).


    Extension requirements
    This plugin requires either cbaseserver tools or connect extensions, read their threads for more info on which one you want to pick (probably down to which games they support).

    Connect: http://forums.alliedmods.net/showthread.php?t=162489
    CBaseServer: http://forums.alliedmods.net/showthread.php?t=72322

    Optionally, you can use the donator plugin, too:
    http://forums.alliedmods.net/showthread.php?t=145542

    About:

    Immunity Reserve Slots is an extended version of *pRED's original plugin for CBaseServer. The best way to understand the plugin is to simply show you the cvar descriptions below.

    The following cvar's are auto created on run in:
    cfg/sourcemod/plugin.immunityreserveslots.cfg

    sm_irs_kicktype
    Default: 0
    Who to kick when a valid player is found (0 - random, 1 - highest ping, 2 - highest time, 3 - lowest time).

    sm_irs_log
    Default: 0
    Enable logging (0 - disable, 1 - enable highly verbose logs, 2 - only log the disconnected and connecting users).

    sm_irs_immunity
    Default: 1
    Enable immunity check (0 - disable, 1 - immunity check if server is full of reserves, 2 - as with 1 but also allow players with high enough immunity and no reserve flag to stay connected).

    sm_irs_kickreason
    Message to display when a client is kicked for a normal reserve slot ("default" - uses translation phrase, anything else uses what you enter).

    sm_irs_kickreason_immunity
    Message to display when a client is kicked for a reserve slot based on immunity ("default" - uses translation phrase, anything else uses what you enter).

    sm_irs_kickspecfirst
    Default: "1"
    When enabled spectators are always kicked first before anyone else (0 - disable, all players are taken into account for kicking, 1 - enable).

    sm_irs_kickspecdelay
    Default: "0"
    The delay, in seconds, to kick spectators (0 - instant, any other value gives spectators a grace of xx seconds until they can be kicked).

    sm_irs_highimmunitylimit
    Default: "0"
    The maximum amount of players that can connect to the server and kick a low immunity reserve slot player (0 - no limit, more than 0 to set the max limit).

    sm_irs_highimmunityvalue
    Default: "0"
    This value and over are players who are considered to have high immunity (0 - disable, more than 0 to set the high immunity value).

    sm_irs_keepbalance
    Default: "0"
    This tries to kick people in such a way to prevent autobalance (0 - disable, 1 - enable).

    sm_irs_rejectreason_enable
    Default: "0"
    Enable reject reason with the Connect extension (0 - disable, 1 - enable).

    sm_irs_rejectreason
    Default: "default"
    Message to display when a client gets rejected for a reserve slot when they have reserve rights with the Connect extension ("default" - uses translation phrase, anything else uses what you enter).

    sm_irs_autopassword
    Default: "0"
    Allow direct connecting reserve slot users to connect without having to type in the password on a password protected server with the Connect extension (0 - disable, 1 - enable, 2 - as with 1 but allow all connecting clients to connect).

    sm_irs_kicklist_mode
    Default: "0"
    Enable kick list mode (0 - disable, normal reserve slot operation, 1 - only use a kick list to kick specific clients, 2 - as with 1 but allow any connecting client to kick people from the server).

    sm_irs_kicklist_file
    Default: "default"
    Path to kick list file ("default" - uses a file in the sourcemod config folder called irs_kicklist.ini, anything else uses what you enter e.g. "cfg/kicklist.cfg").

    sm_irs_donator_support
    Default: "0"
    When enabled along with the donators plugin, donaotrs will be allowed to connect (0 - disable, 1 - allow donators to connect).

    sm_irs_donator_immunity
    Default: "0"
    The immunity value to give to donators, if required for immunity checks within IRS.

    Server Commands:

    sm_irs_kicklist_reload
    Reloads the kick list.

    Installing:

    First you want to install the CBaseServer Tools extension or Connect extension, which are linked above. I highly recommend getting the latest snapshots of either extension.

    To install my plugin simply place the file immunityreserveslots_<ext>.smx into the sourcemod plugins folder and the phrases file into the translation folder on your server.

    To add users to the system add them in your admin config (default: game/addons/sourcemod/configs/admins.cfg) with the reserve flag. If you use the immunity feature of my plugin you'll also want to set their immunity to whichever levels you decide upon. Read the top of the admin config file for more info on immunity.

    Support:

    If you find any problems with the system you will need to provide the FULL logs the plugin creates if you enable logging. This is the only way I can figure out problems with the system. BUT it should be solid now.

    Support is also only provided if you run SM 1.4+.

    To compile the plugin yourself you will need to install the include files for the required extensions which can be found in their threads.

    Special Thanks:

    I really have to thank *pRED for his excellent CBaseServer tools extension as it spurred me into coding action for SourceMod!

    Thanks goes to all the people who've helped me test the plugin.

    Changelog

    2.0.8
    - Added cvar to control when to kick spectators (sm_irs_kickspecdelay, set to 0 instantly kicks spectators, anything else gives them a grace of x secs before being kicked).

    2.0.7
    - Added donator plugin support (see: http://forums.alliedmods.net/showthread.php?t=145542).

    2.0.6
    - Code cleanup.
    - Added support for Connect 1.2.0+.

    2.0.5
    - Fix for non-TF2 games throwing errors on map start. Connect only.

    2.0.4
    - Fix for too many clients connecting in MVM games. Connect only.

    2.0.3
    - Fixed CloseHandle() bug.

    2.0.2
    - Recoded kick list mode for less disk I/O.
    - Fixed a bug if kick list mode was set to 2 which could create a possible rare looping slot scenario.
    - Added command to reload the kick list if users want to update the list as soon as possible (sm_irs_kicklist_reload), list now also updates automatically on map change properly.
    - Cleaned up some code.

    2.0.1
    - Added auto password cvar so reserve clients can automatically connect to password protected servers, can also be set so any connecting client can connect e.g. for temporary purposes (sm_irs_autopassword).
    - Fixed bug in keep balance code where it wouldn't kick spectators if there were any when the cvar for kick spectators first was disabled.
    - Added kick list mode, this allows anyone to connect to the server (configurable) but goes through a list of steam id's for who should get kicked vs who can connect (sm_irs_kicklist_mode and sm_irs_kicklist_file).
    - Removed sm_rescheck_mmunity command check thing I still had in there where it wouldn't have mattered anyway (i.e. I missed it).

    2.0
    - Added Connect extension support.
    - Added cvars to configure the reject message on a full server (sm_irs_rejectreason_enable and sm_irs_rejectreason).

    1.0.4
    - Made use of GetURandomFloat for random mode.
    - Improved logging code.

    1.0.3
    - Made the default action for detected reserve plugins to move to the disabled folder after unload rather than stopping the plugin.
    - Changed translation phrase on plugin error to make more sense.

    1.0.2
    - Fixed incorrect statement in balance check code.
    - Small optimisations.
    - Added command check back in for "sm_reskick_immunity" as some servers might expect this as a valid way to grant default immunity if reading the official SM wiki.
    - Added the regular SM reserve slot plugin to the plugin checks on startup.

    1.0.1
    - Added cvar "sm_irs_keepbalance", this will try and keep team balance best as possible when kicking players as not to trigger an autobalance.
    - Drastic recoding for better performance.
    - Added use of AskPluginLoad2() for improved late load detection (this makes the plugin require SM 1.3 now).
    - Added detection of accidental installation of the default test plugin for CBaseServer tools to avoid any possible problems.
    - New verbose logs, now create their own log files instead of spamming regular logs. Also improved verbosity.
    - Fixed a small leak which happened if any logging was disabled.
    - Spec check now uses a team check instead as in some games it could "incorrectly" flag users as spectating when they were dead. Also flags unassigned players now.

    1.0
    - Made final.
    - Added full translation support.
    - Changed the way the reason cvars work, no config changes needed for old users.

    0.3.4
    - Added a cvar option to limit the maximum amount of players with high immunity to kick low immunity players when the server is full (if more than the value are connected at the time no further connections will be allowed).
    - A bit of code clean up.

    0.3.3
    - Added cvar to control whether or not spectators get kicked first before other players or not (defaults to enabled).

    0.3.2
    - Added option to only log who gets kicked.

    0.3.1
    - Fixed a very small bug in the logging code to do with detecting spectators.

    0.3
    - Fixed some logging bugs.
    - Fixed a major bug in the immunity check and optimised regular check.

    0.2
    - Added lowest time option to kick types.
    - Added cvars to control kick message for normal kick and immunity kick.
    - Small optimizations.

    0.1
    - Initial release
    Attached Files
    File Type: sp Get Plugin or Get Source (immunityreserveslots_src.sp - 812 views - 33.2 KB)
    File Type: smx immunityreserveslots_cbase.smx (13.5 KB, 741 views)
    File Type: smx immunityreserveslots_connect.smx (14.2 KB, 820 views)
    File Type: txt immunityreserveslots.phrases.txt (4.1 KB, 899 views)
    File Type: cfg plugin.immunityreserveslots.cfg (3.9 KB, 881 views)
    File Type: ini irs_kicklist.ini (186 Bytes, 988 views)

    Last edited by Jamster; 02-25-2013 at 09:35. Reason: Updated plugin.
    Jamster is offline
    12345
    Senior Member
    Join Date: Dec 2004
    Old 05-23-2009 , 18:29   Re: Immunity Reserve Slots
    Reply With Quote #2

    This plugin support l4d?
    12345 is offline
    DontWannaName
    Veteran Member
    Join Date: Jun 2007
    Location: VALVe Land, WA
    Old 05-23-2009 , 18:38   Re: Immunity Reserve Slots
    Reply With Quote #3

    cbase doesnt work with L4D so no. Missing the header?
    __________________

    DontWannaName is offline
    Jamster
    Veteran Member
    Join Date: Jun 2008
    Old 05-23-2009 , 19:00   Re: Immunity Reserve Slots
    Reply With Quote #4

    For supported games read pRED's thread linked above, but I don't think it does, no.

    Also, where is my plugin info, submit system still bugged? ;__;
    Jamster is offline
    flubber
    Senior Member
    Join Date: Oct 2007
    Old 05-24-2009 , 14:19   Re: Immunity Reserve Slots
    Reply With Quote #5

    Thanks Jamster for the immunity version, i've just installed it and activate the log, i'll give you feedback asap.
    flubber is offline
    Jamster
    Veteran Member
    Join Date: Jun 2008
    Old 05-24-2009 , 14:36   Re: Immunity Reserve Slots
    Reply With Quote #6

    Thanks. Yeah, as long as you set the immunity cvar to 2 it'll do what you want for your server!
    Jamster is offline
    flubber
    Senior Member
    Join Date: Oct 2007
    Old 05-24-2009 , 14:54   Re: Immunity Reserve Slots
    Reply With Quote #7

    By the way i was thinking of something : A cvar to set the texte message explaining the kick reason.
    flubber is offline
    Jamster
    Veteran Member
    Join Date: Jun 2008
    Old 05-24-2009 , 15:30   Re: Immunity Reserve Slots
    Reply With Quote #8

    It's something I'll note down for a future version.
    Jamster is offline
    HanoverFist
    Member
    Join Date: Oct 2007
    Old 05-24-2009 , 22:00   Re: Immunity Reserve Slots
    Reply With Quote #9

    do I disable the sourcemod reserve slots?

    Last edited by HanoverFist; 05-24-2009 at 22:41.
    HanoverFist is offline
    msleeper
    Veteran Member
    Join Date: May 2008
    Location: Atlanta, Jawjuh
    Old 05-25-2009 , 05:27   Re: Immunity Reserve Slots
    Reply With Quote #10

    Yeah disable the built-in reserved slots.

    I can't wait to use this update when you add in a kick message. Also, can you add "lowest time" to your kick method? I'd rather kick people who just joined recently, than someone who has been on the server for a long time.
    __________________
    msleeper is offline
    Reply


    Thread Tools
    Display Modes

    Posting Rules
    You may not post new threads
    You may not post replies
    You may not post attachments
    You may not edit your posts

    BB code is On
    Smilies are On
    [IMG] code is On
    HTML code is Off

    Forum Jump


    All times are GMT -4. The time now is 06:34.


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