#pragma once class IEngineClient { public: typedef struct player_info_s { union { int64_t xuid; struct { int xuidlow; int xuidhigh; }; }; char name[32]; int userid; char guid[33]; unsigned int friendsid; char friendsname[32]; bool fakeplayer; bool ishltv; unsigned int customfiles[4]; unsigned char filesdownloaded; } player_info_t; void GetScreenSize(int& width, int& height) { typedef void (*oGetScreenSize)(void*, int&, int&); return getvfunc(this, 5)(this, width, height); } bool GetPlayerInfo(int iIndex, player_info_t* pInfo) { typedef bool (*oGetPlayerInfo)(void*, int, player_info_t*); return getvfunc(this, 8)(this, iIndex, pInfo); } int GetPlayerForUserID(int UserID) { typedef int (*oGetPlayerForUserID)(void*, int); return getvfunc(this, 9)(this, UserID); } int GetLocalPlayer() { typedef int (*oGetLocalPlayer)(void*); return getvfunc(this, 12)(this); } void GetViewAngles(QAngle& angle) { typedef void (*oGetViewAngles)(void*, QAngle&); return getvfunc(this, 18)(this, angle); } void SetViewAngles(QAngle& angle) { typedef void (*oSetViewAngles)(void*, QAngle&); return getvfunc(this, 19)(this, angle); } void GetFreeaimAngles(QAngle& angle) { typedef void (*oGetViewAngles)(void*, QAngle&); return getvfunc(this, 20)(this, angle); } void SetFreeaimAngles(QAngle& angle) { typedef void (*oSetViewAngles)(void*, QAngle&); return getvfunc(this, 21)(this, angle); } int GetMaxClients() { typedef int (*oGetMaxClients)(void*); return getvfunc(this, 22)(this); } bool IsInGame() { typedef bool (*oIsInGame)(void*); return getvfunc(this, 28)(this); } bool IsTakingScreenshot() { typedef bool (*oIsTakingScreenshot)(void*); return getvfunc(this, 91)(this); } void ExecuteClientCmd(const char* szCmdString) { typedef void (*oExecuteClientCmd)(void*, const char*); return getvfunc(this, 107)(this, szCmdString); } void ClientCmd_Unrestricted(const char* szCmdString) { typedef void (*oClientCmd_Unrestricted)(void*, const char*); return getvfunc(this, 112)(this, szCmdString); } };