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

[L4D & L4D2] No Friendly-fire (v10.0, 6-1-2022)


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Psyk0tik
Veteran Member
Join Date: May 2012
Location: Homeless
Old 11-26-2017 , 00:12   Re: [L4D & L4D2] No Friendly Fire (v2.0, 11-25-2017)
Reply With Quote #11

Quote:
Originally Posted by Lux View Post
I use these cvars on my server to disable friendly fire, it's a simple way for all survivors not to kill each other.

Thought i would share

PHP Code:
#include <sourcemod>
#include <sdktools>

public Plugin:myinfo =
{
    
name "RemoveFF",
    
author "Lux",
    
description "",
    
version "",
    
url ""
};

public 
OnPluginStart()
{
    
HookEvent("round_start"RoundStart);
    
HookEvent("round_end"RoundStart);
}

public 
Action:RoundStart(Handle:event, const String:name[], bool:dontBroadcast
{
    
SetConVarString(FindConVar("survivor_friendly_fire_factor_easy"), "0");
    
SetConVarString(FindConVar("survivor_friendly_fire_factor_expert"), "0");
    
SetConVarString(FindConVar("survivor_friendly_fire_factor_hard"), "0");
    
SetConVarString(FindConVar("survivor_friendly_fire_factor_normal"), "0");
    
SetConVarString(FindConVar("grenadelauncher_ff_scale"), "0");
    
SetConVarString(FindConVar("survivor_burn_factor_easy"), "0");
    
SetConVarString(FindConVar("survivor_burn_factor_normal"), "0");
    
SetConVarString(FindConVar("survivor_burn_factor_hard"), "0");
    
SetConVarString(FindConVar("survivor_burn_factor_expert"), "0");

Note the cvars stop self damage from explosive ammo too
Thank you for sharing.
__________________
Psyk0tik is offline
 



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 08:57.


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