Raised This Month: $305 Target: $400
 76%   Almost there!

[L4D & L4D2] Left 4 DHooks Direct (1.63) [15-Oct-2021]


Post New Thread Reply   
 
Thread Tools Display Modes
Silvers
AlliedModders Donor
Join Date: Aug 2010
Location: SpaceX
Old 06-18-2021 , 18:08   Re: [L4D & L4D2] Left 4 DHooks Direct (1.41) [18-Jun-2021]
Reply With Quote #331

Pushed update.

Code:
1.41 (18-Jun-2021)
    - L4D2: Fixed "InvulnerabilityTimer" offset. Thanks to "Nuki" for helping.
    - GameData .txt file updated.
__________________
Silvers is offline
foxhound27
Senior Member
Join Date: Sep 2019
Location: Argentina
Old 06-20-2021 , 21:41   Re: [L4D & L4D2] Left 4 DHooks Direct (1.41) [18-Jun-2021]
Reply With Quote #332

thank you!!

Last edited by foxhound27; 06-20-2021 at 21:50.
foxhound27 is offline
sorallll
Member
Join Date: Oct 2018
Old 06-22-2021 , 15:54   Re: [L4D & L4D2] Left 4 DHooks Direct (1.41) [18-Jun-2021]
Reply With Quote #333

Hi,Silvers. Can you add L4D_OnEnterGhostStatePre?
sorallll is offline
Silvers
AlliedModders Donor
Join Date: Aug 2010
Location: SpaceX
Old 06-22-2021 , 18:04   Re: [L4D & L4D2] Left 4 DHooks Direct (1.41) [18-Jun-2021]
Reply With Quote #334

Quote:
Originally Posted by sorallll View Post
Hi,Silvers. Can you add L4D_OnEnterGhostStatePre?
I can add. What's the reason, to block going into ghost state?
__________________
Silvers is offline
sorallll
Member
Join Date: Oct 2018
Old 06-22-2021 , 18:15   Re: [L4D & L4D2] Left 4 DHooks Direct (1.41) [18-Jun-2021]
Reply With Quote #335

Quote:
Originally Posted by Silvers View Post
I can add. What's the reason, to block going into ghost state?
as you said
sorallll is offline
Silvers
AlliedModders Donor
Join Date: Aug 2010
Location: SpaceX
Old 06-22-2021 , 20:30   Re: [L4D & L4D2] Left 4 DHooks Direct (1.42) [23-Jun-2021]
Reply With Quote #336

Code:
1.42 (23-Jun-2021)
    - L4D & L4D2 update:
    - Added forward "L4D_OnVomitedUpon" when client is covered in vomit.
    - Added forward "L4D_OnEnterGhostStatePre" with the ability to block entering ghost state.
    - Changed 2 signatures to be compatible with detouring: "CTerrorPlayer::OnStaggered" and "CTerrorPlayer::OnVomitedUpon".

    - L4D2 update only:

    - Added forward "L4D2_OnHitByVomitJar" when a Bilejar explodes on clients.
    - Added native "L4D2_NavAreaTravelDistance" to return the nav flow distance between two areas.
    - Added native "L4D2_UseAdrenaline" to give a player the Adrenaline effect and health benefits.

    - Added various natives as wrappers executing VScript code:
        - These are slower than native SDKCalls, please report popular ones to convert to fast SDKCalls.
        "L4D2_VScriptWrapper_GetMapNumber"
        "L4D2_VScriptWrapper_HasEverBeenInjured"
        "L4D2_VScriptWrapper_GetAliveDuration"
        "L4D2_VScriptWrapper_IsDead"
        "L4D2_VScriptWrapper_IsDying"
        "L4D2_VScriptWrapper_UseAdrenaline"
        "L4D2_VScriptWrapper_ReviveByDefib"
        "L4D2_VScriptWrapper_ReviveFromIncap"
        "L4D2_VScriptWrapper_GetSenseFlags"
        "L4D2_VScriptWrapper_NavAreaBuildPath"
        "L4D2_VScriptWrapper_NavAreaTravelDistance" // Added as a demonstration and test, SDKCall is available, use "L4D2_NavAreaTravelDistance" instead.

    - Updated: Plugin, GameData and Include file. Both L4D1 and L4D2.
    - Thanks to "Eärendil" for showing me how to call some VScript functions.
Big update!
__________________
Silvers is offline
gamer_kanelita
Senior Member
Join Date: Jun 2019
Location: Peru
Old 06-29-2021 , 10:14   Re: [L4D & L4D2] Left 4 DHooks Direct (1.42) [23-Jun-2021]
Reply With Quote #337

I would like to know how to bind or link L4D2_UseAdrenaline, to give it the effect of adrenaline through any button on the keyboard? :llorar::llorar:
gamer_kanelita is offline
Silvers
AlliedModders Donor
Join Date: Aug 2010
Location: SpaceX
Old 06-29-2021 , 10:35   Re: [L4D & L4D2] Left 4 DHooks Direct (1.42) [23-Jun-2021]
Reply With Quote #338

Quote:
Originally Posted by gamer_kanelita View Post
I would like to know how to bind or link L4D2_UseAdrenaline, to give it the effect of adrenaline through any button on the keyboard? :llorar::llorar:
Create a plugin that calls the native. See https://forums.alliedmods.net/showthread.php?t=333058 for usage and examples. Register a command to call it.
__________________
Silvers is offline
ProjectSky
AlliedModders Donor
Join Date: Aug 2020
Old 06-30-2021 , 12:48   Re: [L4D & L4D2] Left 4 DHooks Direct (1.42) [23-Jun-2021]
Reply With Quote #339

is there any way block ghost state si spawn?
found m_ghostSpawnState, but it need called every frame on the client.

i using this method, i think maybe there is a better solution
PHP Code:
public Action OnPlayerRunCmd(int clientint &buttons)
{
    if (!(
buttons IN_ATTACK)) return Plugin_Continue;
    else if (
GetClientTeam(client) != || IsFakeClient(client) || GetEntProp(clientProp_Send"m_isGhost") != 1) return Plugin_Continue;
    else if (
GetEntProp(clientProp_Send"m_ghostSpawnState") != 0) return Plugin_Continue;

    if (
g_ibalabala)
    {
        
buttons &= ~IN_ATTACK;
        return 
Plugin_Continue;
    }
    return 
Plugin_Continue;

ProjectSky is online now
Silvers
AlliedModders Donor
Join Date: Aug 2010
Location: SpaceX
Old 06-30-2021 , 13:07   Re: [L4D & L4D2] Left 4 DHooks Direct (1.42) [23-Jun-2021]
Reply With Quote #340

The recently added forward "L4D_OnEnterGhostStatePre" can block this, but they'll remain in dead state for a while then I think the game auto spawns them or something. See the test plugin for example on usage + blocking. What you could do is then spawn them. Have a look at the natives: L4D_RespawnPlayer, L4D_State_Transition, L4D_MaterializeFromGhost, L4D_SetClass. Not sure which is best to use, play around with it.
__________________
Silvers 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 18:54.


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