Raised This Month: $ Target: $400
 0% 

Solved null


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
alasfourom
Senior Member
Join Date: Feb 2022
Location: Saudi Arabia
Old 07-05-2022 , 14:15   Re: [L4D2] Speed Booster
Reply With Quote #4

Thanks Marttt,

I tried to use HookEvent, because I want to disable it once charging start not necessary when charging a survivor

PHP Code:
    HookEvent ("charger_charge_start"Event_InfectedAbilityStart);
    
HookEvent ("charger_pummel_start"Event_InfectedAbilityStart);
    
HookEvent ("choke_start",     Event_InfectedAbilityStart);
    
HookEvent ("lunge_pounce"Event_InfectedAbilityStart);
    
HookEvent ("jockey_ride"Event_InfectedAbilityStart); 
I'm a bit confused with it, tried many ways but not sure how to make it work.

PHP Code:
public void Event_InfectedAbilityStart (Event event, const char[] namebool dontBroadcast)
{
    
int client GetClientOfUserId (event.GetInt("userid"));
    if (
client && IsClientInGame(client) && !IsFakeClient(client) && IsInfected(client))
    {
        
Speeding [client] = false;
        
SetEntPropFloat (clientProp_Data"m_flLaggedMovementValue"1.0);
    }
    return;

I tried different ways but still didnt work for me

Last edited by alasfourom; 07-07-2022 at 04:11.
alasfourom 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 00:59.


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