Updated SDKTools IServer finding on Windows for Ep2v and CSS (bug 5450, r=me).
This commit is contained in:
parent
bf4bce8250
commit
0d6b93c5a0
@ -127,14 +127,22 @@ void GetIServer()
|
|||||||
|
|
||||||
#if defined METAMOD_PLAPI_VERSION || PLAPI_VERSION >= 11
|
#if defined METAMOD_PLAPI_VERSION || PLAPI_VERSION >= 11
|
||||||
/* Get the CreateFakeClient function pointer */
|
/* Get the CreateFakeClient function pointer */
|
||||||
|
#if SOURCE_ENGINE == SE_ORANGEBOXVALVE
|
||||||
|
if (!(vfunc=SH_GET_ORIG_VFNPTR_ENTRY(engine, &IVEngineServer::CreateFakeClientEx)))
|
||||||
|
#else
|
||||||
if (!(vfunc=SH_GET_ORIG_VFNPTR_ENTRY(engine, &IVEngineServer::CreateFakeClient)))
|
if (!(vfunc=SH_GET_ORIG_VFNPTR_ENTRY(engine, &IVEngineServer::CreateFakeClient)))
|
||||||
|
#endif
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
/* Get the interface manually */
|
/* Get the interface manually */
|
||||||
SourceHook::MemFuncInfo info = {true, -1, 0, 0};
|
SourceHook::MemFuncInfo info = {true, -1, 0, 0};
|
||||||
|
#if SOURCE_ENGINE == SE_ORANGEBOXVALVE
|
||||||
|
SourceHook::GetFuncInfo(&IVEngineServer::CreateFakeClientEx, info);
|
||||||
|
#else
|
||||||
SourceHook::GetFuncInfo(&IVEngineServer::CreateFakeClient, info);
|
SourceHook::GetFuncInfo(&IVEngineServer::CreateFakeClient, info);
|
||||||
|
#endif
|
||||||
|
|
||||||
vfunc = enginePatch->GetOrigFunc(info.vtbloffs, info.vtblindex);
|
vfunc = enginePatch->GetOrigFunc(info.vtbloffs, info.vtblindex);
|
||||||
if (!vfunc)
|
if (!vfunc)
|
||||||
|
@ -141,7 +141,7 @@
|
|||||||
{
|
{
|
||||||
"Keys"
|
"Keys"
|
||||||
{
|
{
|
||||||
/* Signature for the beginning of IVEngineServer::CreateFakeClient.
|
/* Signature for the beginning of IVEngineServer::CreateFakeClientEx.
|
||||||
*
|
*
|
||||||
* The engine binary is not actually scanned in order to look for
|
* The engine binary is not actually scanned in order to look for
|
||||||
* this. SourceHook is used to used to determine the address of the
|
* this. SourceHook is used to used to determine the address of the
|
||||||
@ -149,7 +149,7 @@
|
|||||||
* the expected code. A pointer to sv (IServer interface) is used
|
* the expected code. A pointer to sv (IServer interface) is used
|
||||||
* here.
|
* here.
|
||||||
*/
|
*/
|
||||||
"CreateFakeClient_Windows" "\x55\x8B\xEC\x8B\x45\x2A\x50\xB9\x2A\x2A\x2A\x2A\xE8\x2A\x2A\x2A\x2A\x85\xC0"
|
"CreateFakeClient_Windows" "\x55\x8B\xEC\x8B\x2A\x2A\x8A\x2A\x2A\x51\xB9\x2A\x2A\x2A\x2A\xA2"
|
||||||
}
|
}
|
||||||
|
|
||||||
"Offsets"
|
"Offsets"
|
||||||
@ -157,7 +157,7 @@
|
|||||||
/* Offset into IVEngineServer::CreateFakeClient */
|
/* Offset into IVEngineServer::CreateFakeClient */
|
||||||
"sv"
|
"sv"
|
||||||
{
|
{
|
||||||
"windows" "8"
|
"windows" "11"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user