r5sdk/r5dev/client/client.h
Kawe Mazidjatari b753295a49 SDK improvements
* Dedicated SDK now supports ASLR enabled executables.
* Complete removal of CEngineClient on the dedicated server.
* Complete removal of gHLClient and g_pHLClient on the dedicated server.
* Performance improvements for the dedicated server frame loop.
* ConVar 'CVCallback_t' structure rebuild.
* Reduced overhead throughout SDK.
2022-04-14 19:18:59 +02:00

28 lines
1.3 KiB
C++

#ifndef CLIENT_H
#define CLIENT_H
#if defined (GAMEDLL_S0) || defined (GAMEDLL_S1)
inline CMemory CClientState__RunFrame = g_mGameDll.FindPatternSIMD(reinterpret_cast<rsig_t>("\x48\x89\x4C\x24\x00\x57\x48\x81\xEC\x00\x00\x00\x00\x83\xB9\x00\x00\x00\x00\x00"), "xxxx?xxxx????xx?????");
#elif defined (GAMEDLL_S2) || defined (GAMEDLL_S3)
inline CMemory CClientState__RunFrame = g_mGameDll.FindPatternSIMD(reinterpret_cast<rsig_t>("\x40\x53\x48\x81\xEC\x00\x00\x00\x00\x83\xB9\x00\x00\x00\x00\x00\x48\x8B\xD9\x7D\x0B"), "xxxxx????xx?????xxxxx");
#endif
///////////////////////////////////////////////////////////////////////////////
class HClient : public IDetour
{
virtual void GetAdr(void) const
{
std::cout << "| FUN: CClientState::RunFrame : 0x" << std::hex << std::uppercase << CClientState__RunFrame.GetPtr() << std::setw(nPad) << " |" << std::endl;
std::cout << "+----------------------------------------------------------------+" << std::endl;
}
virtual void GetFun(void) const { }
virtual void GetVar(void) const { }
virtual void GetCon(void) const { }
virtual void Attach(void) const { }
virtual void Detach(void) const { }
};
///////////////////////////////////////////////////////////////////////////////
REGISTER(HClient);
#endif // CLIENT_H