Monthly Target: $400 Donations: $147
 36% 

[L4D] Friendly-Fire Limit (1.1.1)


Post New Thread Reply   
 
Thread Tools Display Modes
Author
-pk-
Member
Join Date: Feb 2009
Plugin ID:
766
Plugin Version:
1.1.1
Plugin Category:
Gameplay
Plugin Game:
Left 4 Dead
Plugin Dependencies:
    Servers with this Plugin:
    12 
    Plugin Description:
    Limits friendly-fire damage for Survivors and includes important features for servers.
    Old 02-11-2009 , 23:43   [L4D] Friendly-Fire Limit (1.1.1)
    Reply With Quote #1

    Friendly-Fire Limit (1.1.1)

    This plugin limits friendly-fire damage for Survivors and includes important features for servers. Unlike other plugins, this allows you to keep friendly-fire enabled on your server and set a FF cap per player in case someone trys to grief mid-game.


    Features:
    • Friendly-Fire is always disabled in the saferoom. In addition, you can limit the amount of FF damage a player can deal, or remove friendly-fire from an entire map.
    • When a Friendly-Fire limit is set, any FF damage that a player does above that limit is ignored.
    • You can limit the amount of FF that a player can deal to his Team (l4d_ff_limit) and each Teammate (l4d_ff_teammate).
    • You can limit the amount of FF damage from Grenades/Fire, with both a "soft cap" and "hard cap".
    • You can choose to notify admins when a player reaches the FF limit and/or ban the player automatically (Admin immune). Supports SourceBans.
    • Option to log notifications and bans.
    • Option to Announce FF Status to players (Survivors only).
    • Works in Coop, Versus, and custom maps.
    Notes:
    • l4d_ff_limit must be set to 40 or higher in order to ban with FF damage dealt to Team.
    • l4d_ff_teammate must be set to 30 or higher in order to ban with damage dealt to a Teammate.
    • l4d_ff_limit.cfg is executed on each map change, so any changes made ingame will be cleared. You may add map specific Limit settings to your server's map configs.
    • I will not add a kick feature because the player could rejoin the server and grief all over again. You should use a short ban duration (5-10 minutes) if you want to use it as a kick feature.
    • I will not add notification for the player when they have reached the FF limit. This is to prevent players from autoshotgun spamming pounced victims once they know they can no longer hurt their team.
    CVars:
    Code:
    l4d_ff_limit 60                 // -1 = Block All Damage (full map), 0 = Block All Damage (saferoom only), any other = Player can deal this much damage to his entire Team.
    l4d_ff_teammate 30              // (limit > 0) Player can deal this much damage to each teammate.
    l4d_ff_grendmg_min 20           // (limit > 0) Grenade or Fire damage above this value will still hurt, but will not count against the player's FF limit. any value = Only count this much grendmg, -1 = infinite.
    l4d_ff_grendmg_max_team 40      // (limit > 0) Player can deal this much Grenade or Fire damage to Team before the damage is prevented. 0 = infinite.
    l4d_ff_grendmg_max_teammate 15  // (limit > 0) Player can deal this much Grenade or Fire damage to Teammate before the damage is prevented. 0 = infinite.
    l4d_ff_ban 0                    // 0 = no action, 1 = Ban only if player reaches Team FF limit (limit = 40+), 2 = Ban whichever comes first (limit = 40+) or (teammate = 30+). Use negative values if you require ban by IP address.
    l4d_ff_banduration 0            // (ban > 0) Ban Duration in minutes. 0 = Don't ban but warn the player if they may be permbanned.
    l4d_ff_permban_x 3              // Valid between 2 to 5. A value of 2 will permanently ban the player on their 2nd offense, etc.
    l4d_ff_permban_y 30             // (ban > 0) Only count the number of times the player was warned/banned within this many days. 0 = don't perm ban, any other = number of days.
    l4d_ff_log 1                    // Log players that are banned or reach the FF limit (FriendlyFire.log). 0 = Disable, 1 = Enable.
    l4d_ff_notify 1                 // Notification when players reach the FF limit. 1 = Notify Admins.
    l4d_ff_announce 1               // For Survivors only.  0 = Don't Announce, 1 = Announce Active/Inactive Status (limit = 0) or Announce Limit (limit > 0)
    Changelog:

    1.1.1 (02-21-2009)
    Players will now be logged when they receive a permban warning.
    Fix a player who is warned instead of being banned will no longer have their damage reset.
    Fix admins will no longer be notified that a player has reached the FF limit while the player is being banned.
    1.1.0 (02-18-2009)
    Expert difficulty, (if greater than 0) l4d_ff_limit will be set to 0 (saferoom only) and l4d_ff_teammate will be disabled automatically.
    Advanced difficulty, (if greater than 0) l4d_ff_limit and l4d_ff_teammate will be multiplied by 4.5, and l4d_ff_grenmin will be multilpied by 2.
    1.0.9 (02-17-2009)
    Add cvars l4d_ff_permban_x and l4d_ff_permban_y, X number of bans allowed within Y days until a player is permanently banned.
    If ban duration is set to 0, and l4d_ff_ban is set to 1 or 2, and l4d_ff_permban_y is greater than 0 Days, a player will recieve a warning instead of being banned. The player will be permanently banned once they reach l4d_ff_permban_x warnings/bans.
    1.0.8 (02-15-2009)
    Fix bug in 1.0.7 causing missing name in chat when player is banned.
    1.0.7 (02-14-2009)
    Add ability to ban by IP address instead of clientID, by entering negative l4d_ff_ban values.
    1.0.6 (02-14-2009)
    Admins are immune if they have any of the following flags "abcdfz"
    Fix accidentally banning admins after rewriting the code in 1.0.4.
    Fix grenade damage can now be dealt to a player after reaching the Teammate FF limit, as long as the damage is above grendmg_min (where damage will not be counted as FF) and below grendmg_max.
    1.0.5 (02-13-2009)
    Add l4d_ff_grendmg_min = -1 (infinite).
    1.0.4 (02-13-2009)
    Fix bug when l4d_ff_grendmg_min = 0 (do not count as FF).
    1.0.3 (02-13-2009)
    Add cvar l4d_ff_grendmg_min, Grenade or Fire damage above this value will still hurt, but will not count against the player's FF limit.
    Add cvar l4d_ff_grendmg_max_team, a player can deal this much Grenade or Fire damage to Team before the damage is prevented.
    Add cvar l4d_ff_grendmg_max_teammate, a player can deal this much Grenade or Fire damage to Teammate before the damage is prevented.
    Damage to incapacitated players will no longer count towards FF limit, and will deal the normal damage.
    1.0.2 (02-12-2009)
    Add cvar l4d_ff_teammate, limit max FF that can be dealt to a teammate.
    Add cvar l4d_ff_ban, ban method.
    Add: player's steamid is now logged.
    Improved Coop detection of player left saferoom.
    Fix bug when a player that has gone over the limit could sometimes heal a teammate with FF damage.
    1.0.1 (02-11-2009)
    Add support for SourceBans.
    1.0.0 (02-11-2009)
    initial release.


    Credits:
    Original concept by r5053
    Big Thanks to Testers: Number Six

    Requires: SM 1.2
    Attached Files
    File Type: cfg l4d_ff_limit.cfg (1.7 KB, 2402 views)
    File Type: smx l4d_ff_limit.smx (12.4 KB, 1764 views)
    File Type: sp Get Plugin or Get Source (l4d_ff_limit.sp - 3146 views - 28.4 KB)

    Last edited by -pk-; 02-21-2009 at 20:58.
    -pk- is offline
    Number Six
    Senior Member
    Join Date: Dec 2008
    Old 02-12-2009 , 01:13   Re: [L4D] Friendly-Fire Limit
    Reply With Quote #2

    Hi and thank for the pluggin .

    "any other = Limit of friendly fire damage allowed per player."

    Question :
    For the map or just the started spawn in the saferoom ?

    Ps: yes , need a kick option if it's for the map ^^ .

    UPDATE : OK its for the map complete ^^ , good idea !
    Bugs report :
    -With pills use , strange bug graphic appear on heal hud barrel (?)
    -If admin over the definite limit , all tk give heal survivor lol
    __________________



    Last edited by Number Six; 02-12-2009 at 02:02.
    Number Six is offline
    -pk-
    Member
    Join Date: Feb 2009
    Old 02-12-2009 , 01:44   Re: [L4D] Friendly-Fire Limit
    Reply With Quote #3

    It is for the map. The plugin will block all FF in the saferoom, this does not count toward the limit.

    For kick, use a small ban duration of 5 minutes or less. You should do this to prevent a player from using "retry" in console to grief again.



    1.0.1
    Add support for SourceBans.

    *SourceBans should work but is untested (I don't have it installed).

    Last edited by -pk-; 02-12-2009 at 01:48.
    -pk- is offline
    Number Six
    Senior Member
    Join Date: Dec 2008
    Old 02-12-2009 , 01:52   Re: [L4D] Friendly-Fire Limit
    Reply With Quote #4

    Quote:
    Originally Posted by -pk- View Post
    It is for the map. The plugin will block all FF in the saferoom, this does not count toward the limit.

    For kick, use a small ban duration of 5 minutes or less. You should do this to prevent a player from using "retry" in console to grief again.



    1.0.1
    Add support for SourceBans.

    *SourceBans should work but is untested (I don't have it installed).
    Tested now , join me for look
    Ip adress on my banner .

    update :
    if admin over limit give heal survivor and give god mod , no possibly killing survivor , strange bug .
    Sincerely its a really good idea , but need massive fix bugs and debugging for a final install ;)
    __________________



    Last edited by Number Six; 02-12-2009 at 02:01.
    Number Six is offline
    -pk-
    Member
    Join Date: Feb 2009
    Old 02-12-2009 , 02:14   Re: [L4D] Friendly-Fire Limit
    Reply With Quote #5

    My example settings for "Normal" difficulties,


    Anti-Grief and Noob-Friendly Server :

    l4d_ff_limit "60"
    l4d_ff_teammate "35"
    l4d_ff_grendmg_min "-1"
    l4d_ff_grendmg_max_team "40"
    l4d_ff_grendmg_max_teammate "15"
    l4d_ff_ban "0"
    l4d_ff_banduration "0"
    l4d_ff_log "0"
    l4d_ff_notify "1"
    l4d_ff_announce "1"


    or banning while taking into consideration the fire damage,

    Ban 1 (Player must do atleast 40+ damage to team using weapons) :

    l4d_ff_limit "60"
    l4d_ff_teammate "30"
    l4d_ff_grendmg_min "20"
    l4d_ff_grendmg_max_team "40"
    l4d_ff_grendmg_max_teammate "15"
    l4d_ff_ban "1"
    l4d_ff_banduration "60"
    l4d_ff_log "1"
    l4d_ff_notify "1"
    l4d_ff_announce "1"


    Ban 2 (Player must do atleast 40+ damage to team or 30+ damage to teammate using weapons) :

    l4d_ff_limit "50"
    l4d_ff_teammate "40"
    l4d_ff_grendmg_min "10"
    l4d_ff_grendmg_max_team "40"
    l4d_ff_grendmg_max_teammate "15"
    l4d_ff_ban "2"
    l4d_ff_banduration "60"
    l4d_ff_log "1"
    l4d_ff_notify "1"
    l4d_ff_announce "1"


    Edit: moved this post to the front page.

    Last edited by -pk-; 02-15-2009 at 14:20.
    -pk- is offline
    Number Six
    Senior Member
    Join Date: Dec 2008
    Old 02-12-2009 , 02:20   Re: [L4D] Friendly-Fire Limit
    Reply With Quote #6

    Quote:
    Originally Posted by -pk- View Post
    Yes once you reach the FF limit, you can not deal any more FF damage. l4d_ff_limit is per attacker, so the other players can still deal FF damage until they reach their own FF limit.

    This is good for two server setups:
    1. Ban griefers.
    2. Don't Ban. Allow FF damage up to a small limit (l4d_ff_limit of about 25-30). This will allow the "normal gameplay" feel, but with protection from griefers and noob-friendly.


    Soon I will limit FF dealt to each teammate, to prevent the full FF limit being used on a single teammate. Should be better against griefers, making it impossible for a player to ruin the game.
    True !
    And additionnal pressure on players et gameplay ^^

    But please look for the bug if admin over the limit , give heal and god mod is not normal ^^ , but apparently working 100% for simple player . (tested with bots)
    My settings server are (3/4 time avanced versus) .
    l4d_ff_limit 80
    l4d_ff_banduration 5
    l4d_ff_notify 1
    l4d_ff_log 0
    l4d_ff_announce 1

    If over 80 (me admin) , all new tk allow give heal and give god mod if re-tk several for the survivors .
    Immune admin work , no banning for my all tk lol , but not tested with simple player if auto banned .
    __________________



    Last edited by Number Six; 02-12-2009 at 02:35.
    Number Six is offline
    Naow
    Senior Member
    Join Date: Feb 2009
    Old 02-12-2009 , 04:47   Re: [L4D] Friendly-Fire Limit
    Reply With Quote #7

    l4d_ff_announce 1 // 0 = Don't Announce, 1 = Announce Active/Inactive Status (limit = 0)

    I dont see any announce active/inactive , i block TK only at the beginning.
    Naow is offline
    -pk-
    Member
    Join Date: Feb 2009
    Old 02-12-2009 , 14:37   Re: [L4D] Friendly-Fire Limit
    Reply With Quote #8

    Quote:
    Originally Posted by Number Six View Post
    If over 80 (me admin) , all new tk allow give heal and give god mod if re-tk several for the survivors .
    Immune admin work , no banning for my all tk lol , but not tested with simple player if auto banned .
    Thanks, I found the bug. When it tried to ban you, it resets your damage back to 0 thinking you were banned. I'll post fix in next version.
    Edit: looks like it's a two-part bug.

    Quote:
    Originally Posted by Naow View Post
    l4d_ff_announce 1 // 0 = Don't Announce, 1 = Announce Active/Inactive Status (limit = 0)

    I dont see any announce active/inactive , i block TK only at the beginning.
    It should announce for Survivors only. Next version I will improve the saferoom detection for coop. Also make sure you set it with the config instead of using console, or it will reset back to default on map change.

    Last edited by -pk-; 02-12-2009 at 22:13.
    -pk- is offline
    -pk-
    Member
    Join Date: Feb 2009
    Old 02-12-2009 , 21:10   Re: [L4D] Friendly-Fire Limit
    Reply With Quote #9

    New version 1.0.2 is released. Config updated with new cvars.

    - Add cvar l4d_ff_teammate, limit max FF that can be dealt to a teammate.
    - Add cvar l4d_ff_ban, ban method.
    - Add: player's steamid is now logged.
    - Improved Coop detection of player left saferoom.
    - Fix bug where cfg's would not update the limits properly.
    - Fix bug when a player that has gone over the limit could sometimes heal a teammate with FF damage.

    Last edited by -pk-; 02-21-2009 at 14:27.
    -pk- is offline
    Number Six
    Senior Member
    Join Date: Dec 2008
    Old 02-13-2009 , 02:46   Re: [L4D] Friendly-Fire Limit
    Reply With Quote #10

    tested ,and work finaly fine 1.0.2 ;) .
    gampleplay is good with , just a suggest , with the molotov or fire !
    If a player firing all others , or 1 several , HP go up too more and the player banned fast , and its not specialy faulty or intentional Tk.
    Possibly add cvar 1/0 fire effect damage (?)

    Other suggest . Sourcemod inclued funny plugin , again with css for the Tk , punishement possibly for l4D !
    __________________



    Last edited by Number Six; 02-13-2009 at 03:04.
    Number Six 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 02:37.


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