From 8c2be5523333921d81cffbfda6e6c6c4d200e1a5 Mon Sep 17 00:00:00 2001 From: David Anderson Date: Thu, 30 Mar 2006 00:31:33 +0000 Subject: [PATCH] added ClientUserInfoChanged forward --- dlls/fakemeta/forward.cpp | 16 ++++++++++++++++ dlls/fakemeta/forward.h | 1 + 2 files changed, 17 insertions(+) diff --git a/dlls/fakemeta/forward.cpp b/dlls/fakemeta/forward.cpp index 4d4cfc57..92ab779c 100755 --- a/dlls/fakemeta/forward.cpp +++ b/dlls/fakemeta/forward.cpp @@ -80,6 +80,18 @@ SIMPLE_INT_HOOK_STRING(PrecacheModel); // pfnPrecacheSound SIMPLE_INT_HOOK_STRING(PrecacheSound); +void ClientUserInfoChanged(edict_t *e, char *infobuffer) +{ + FM_ENG_HANDLE(FM_ClientInfoChanged, ((cell)ENTINDEX(e))); + RETURN_META(mswi(lastFmRes)); +} + +void ClientUserInfoChanged_post(edict_t *e, char *infobuffer) +{ + FM_ENG_HANDLE_POST(FM_ClientInfoChanged, ((cell)ENTINDEX(e))); + RETURN_META(mswi(lastFmRes)); +} + void SetModel(edict_t *e, const char *m) { FM_ENG_HANDLE(FM_SetModel, (Engine[FM_SetModel].at(i), ENTINDEX(e), m)); @@ -1128,6 +1140,10 @@ static cell AMX_NATIVE_CALL register_forward(AMX *amx, cell *params) fId = MF_RegisterSPForwardByName(amx, funcname, FP_CELL, FP_CELL, FP_DONE); NEWDLLHOOK(ShouldCollide); break; + case FM_ClientInfoChanged: + fId = MF_RegisterSPForwardByName(amx, funcname, FP_CELL, FP_DONE); + DLLHOOK(ClientUserInfoChanged); + break; #if 0 // I know this does not fit with DLLFUNC(), but I dont want another native just for it. diff --git a/dlls/fakemeta/forward.h b/dlls/fakemeta/forward.h index 89389802..6b2625aa 100755 --- a/dlls/fakemeta/forward.h +++ b/dlls/fakemeta/forward.h @@ -156,6 +156,7 @@ enum { FM_GameShutdown, FM_ShouldCollide, // FM_CvarValue + FM_ClientInfoChanged, FM_LAST_DONT_USE_ME, };