AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Plugins (https://forums.alliedmods.net/forumdisplay.php?f=108)
-   -   [L4D] Friendly-Fire Limit (1.1.1) (https://forums.alliedmods.net/showthread.php?t=85515)

-pk- 02-11-2009 22:43

[L4D] Friendly-Fire Limit (1.1.1)
 
3 Attachment(s)
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

Number Six 02-12-2009 00:13

Re: [L4D] Friendly-Fire Limit
 
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

-pk- 02-12-2009 00:44

Re: [L4D] Friendly-Fire Limit
 
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).

Number Six 02-12-2009 00:52

Re: [L4D] Friendly-Fire Limit
 
Quote:

Originally Posted by -pk- (Post 760213)
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 :D , no possibly killing survivor , strange bug .
Sincerely its a really good idea , but need massive fix bugs and debugging for a final install ;)

-pk- 02-12-2009 01:14

Re: [L4D] Friendly-Fire Limit
 
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.

Number Six 02-12-2009 01:20

Re: [L4D] Friendly-Fire Limit
 
Quote:

Originally Posted by -pk- (Post 760223)
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 .

Naow 02-12-2009 03:47

Re: [L4D] Friendly-Fire Limit
 
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.

-pk- 02-12-2009 13:37

Re: [L4D] Friendly-Fire Limit
 
Quote:

Originally Posted by Number Six (Post 760226)
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 (Post 760265)
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.

-pk- 02-12-2009 20:10

Re: [L4D] Friendly-Fire Limit
 
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.

Number Six 02-13-2009 01:46

Re: [L4D] Friendly-Fire Limit
 
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 ! :mrgreen:


All times are GMT -4. The time now is 01:11.

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