diff --git a/extensions/dhooks/natives.cpp b/extensions/dhooks/natives.cpp index c725947bd..976f00717 100644 --- a/extensions/dhooks/natives.cpp +++ b/extensions/dhooks/natives.cpp @@ -22,7 +22,7 @@ IPluginFunction *GetCallback(IPluginContext *pContext, HookSetup * setup, const { IPluginFunction *ret = NULL; - if (params[0] >= callback_index) + if (static_cast(params[0]) >= callback_index) { ret = pContext->GetFunctionById(params[callback_index]); } @@ -61,7 +61,7 @@ cell_t Native_AddParam(IPluginContext *pContext, const cell_t *params) return 0; } - ParamInfo info; + ::ParamInfo info; info.type = (HookParamType)params[2]; diff --git a/extensions/dhooks/vhook.h b/extensions/dhooks/vhook.h index a9e2b0962..ca9218c65 100644 --- a/extensions/dhooks/vhook.h +++ b/extensions/dhooks/vhook.h @@ -3,11 +3,14 @@ #include "extension.h" -#include +#include #include + #include #include +using namespace sp; + enum MRESReturn { MRES_ChangedHandled = -2, // Use changed values and return MRES_Handled @@ -122,7 +125,7 @@ public: class DHooksInfo { public: - SourceHook::CVector params; + SourceHook::CVector<::ParamInfo> params; int offset; unsigned int returnFlag; ReturnType returnType; @@ -304,7 +307,7 @@ public: ReturnType returnType; HookType hookType; ThisPointerType thisType; - SourceHook::CVector params; + SourceHook::CVector<::ParamInfo> params; int offset; IPluginFunction *callback; };