diff --git a/src/hooks.c b/src/hooks.c index ca31684..3d0fb8c 100644 --- a/src/hooks.c +++ b/src/hooks.c @@ -9,10 +9,12 @@ DECL_HOOK(CL_CreateMove); DECL_HOOK(HUD_Redraw); +DECL_HOOK(StudioRenderModel); bool hooks_init(void) { HOOK(i_client, CL_CreateMove); HOOK(i_client, HUD_Redraw); + HOOK(i_studiomodelrenderer, StudioRenderModel); return true; } @@ -51,3 +53,9 @@ int h_HUD_Redraw(float time, int intermission) { return ret; } + +void h_StudioRenderModel(void* this_ptr) { + ORIGINAL(StudioRenderModel, this_ptr); + + printf("Hi from StudioRenderModel!\n"); +} diff --git a/src/include/hooks.h b/src/include/hooks.h index b176004..f4cac04 100644 --- a/src/include/hooks.h +++ b/src/include/hooks.h @@ -62,5 +62,6 @@ bool hooks_init(void); DECL_HOOK_EXTERN(void, CL_CreateMove, float, usercmd_t*, int); DECL_HOOK_EXTERN(int, HUD_Redraw, float, int); +DECL_HOOK_EXTERN(void, StudioRenderModel, void* this_ptr); #endif /* HOOKS_H_ */