Raised This Month: $32 Target: $400
 8% 

Solved Player Index from Dhooks Detour


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Spirit_12
Veteran Member
Join Date: Dec 2012
Location: Toronto, CA
Old 08-11-2018 , 15:47   Player Index from Dhooks Detour
Reply With Quote #1

PHP Code:
_DWORD __cdecl CDirector::OnFirstSurvivorLeftSafeArea(CDirector *thisCTerrorPlayer *) 
I need to get the index of the player who revoked it.
__________________

Last edited by Spirit_12; 08-11-2018 at 16:53.
Spirit_12 is offline
nosoop
Veteran Member
Join Date: Aug 2014
Old 08-11-2018 , 15:59   Re: Player Index from Dhooks Detour
Reply With Quote #2

DHookAddParam(hDetour, HookParamType_CBaseEntity); // this is the only param for the detoured function

And in the callback:

int client = DHookGetParam(hParams, 1);
__________________
I do TF2, TF2 servers, and TF2 plugins.
I don't do DMs over Discord -- PM me on the forums regarding inquiries.
AlliedModders Releases / Github / TF2 Server / Donate (BTC / BCH / coffee)

Last edited by nosoop; 08-11-2018 at 16:01.
nosoop is offline
Spirit_12
Veteran Member
Join Date: Dec 2012
Location: Toronto, CA
Old 08-11-2018 , 16:49   Re: Player Index from Dhooks Detour
Reply With Quote #3

That's the first thing that I tried. Then I gave it another shot after your post and it worked. Am I going insane ?
__________________
Spirit_12 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 20:22.


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