2023-11-14 22:58:51 +08:00
|
|
|
|
2023-11-23 23:56:11 +08:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#define GAMESTATE_WAIT_CONNECT 1
|
|
|
|
|
2023-11-14 22:58:51 +08:00
|
|
|
struct struc_41
|
|
|
|
{
|
|
|
|
char field_0;
|
|
|
|
int field_1;
|
|
|
|
char _gap5[17];
|
|
|
|
float field_16;
|
|
|
|
char field_1A;
|
|
|
|
char _gap1B[4];
|
|
|
|
char field_1F;
|
|
|
|
char field_20;
|
|
|
|
char field_21;
|
|
|
|
char field_22;
|
|
|
|
int field_23;
|
|
|
|
float field_27;
|
|
|
|
char _gap2B;
|
|
|
|
char field_2C;
|
|
|
|
char field_2D;
|
|
|
|
char field_2E;
|
|
|
|
char field_2F;
|
|
|
|
char _gap30[10];
|
|
|
|
};
|
|
|
|
|
2024-02-06 22:01:20 +08:00
|
|
|
typedef struct _NETGAME_POOLS {
|
2024-02-06 22:08:24 +08:00
|
|
|
CVehiclePool *pVehiclePool;
|
2024-02-06 22:20:05 +08:00
|
|
|
CPlayerPool *pPlayerPool;
|
2024-02-07 23:59:04 +08:00
|
|
|
CPickupPool *pPickupPool;
|
2024-02-12 20:10:26 +08:00
|
|
|
CObjectPool *pObjectPool;
|
2024-02-12 20:12:15 +08:00
|
|
|
CActorPool *pActorPool;
|
2024-02-18 21:21:09 +08:00
|
|
|
CGangZonePool *pGangZonePool;
|
2024-02-12 20:16:37 +08:00
|
|
|
CLabelPool *pLabelPool;
|
2024-02-16 22:32:25 +08:00
|
|
|
CTextDrawPool *pTextDrawPool;
|
2024-02-12 20:22:51 +08:00
|
|
|
CMenuPool *pMenuPool;
|
2024-02-06 22:01:20 +08:00
|
|
|
} NETGAME_POOLS;
|
|
|
|
|
2023-11-14 22:58:51 +08:00
|
|
|
class CNetGame // size: 994
|
|
|
|
{
|
|
|
|
private:
|
2024-01-31 23:57:40 +08:00
|
|
|
|
|
|
|
RakClientInterface *m_pRakClient;
|
|
|
|
|
2024-03-16 23:28:06 +08:00
|
|
|
void UpdateNetwork();
|
|
|
|
|
2023-11-14 22:58:51 +08:00
|
|
|
char _gap4[44];
|
2023-11-23 23:56:11 +08:00
|
|
|
char m_szHostOrIp[257];
|
|
|
|
char m_szHostName[257];
|
2023-11-14 22:58:51 +08:00
|
|
|
char field_232;
|
|
|
|
char field_233;
|
|
|
|
char field_234;
|
2023-11-23 23:56:11 +08:00
|
|
|
int m_iPort;
|
2023-11-14 22:58:51 +08:00
|
|
|
int field_239;
|
2024-02-21 19:04:26 +08:00
|
|
|
DWORD m_dwMapIcon[100];
|
2023-11-23 23:56:11 +08:00
|
|
|
int m_iGameState;
|
2023-11-14 22:58:51 +08:00
|
|
|
int field_3D1;
|
|
|
|
struc_41 *field_3D5;
|
|
|
|
char field_3D9;
|
2024-02-06 22:01:20 +08:00
|
|
|
char _gap3DA[4];
|
|
|
|
NETGAME_POOLS* m_pPools;
|
2023-11-14 22:58:51 +08:00
|
|
|
|
|
|
|
public:
|
|
|
|
|
2024-07-19 23:15:22 +08:00
|
|
|
CNetGame(PCHAR szHostOrIp,int iPort,PCHAR szPlayerName,PCHAR szPass);
|
2024-01-06 23:39:04 +08:00
|
|
|
|
2024-03-16 23:28:06 +08:00
|
|
|
void Process();
|
|
|
|
|
2024-02-06 22:01:20 +08:00
|
|
|
void InitPools();
|
|
|
|
|
2024-01-06 23:39:04 +08:00
|
|
|
DWORD GetTime();
|
|
|
|
|
2024-02-16 22:15:16 +08:00
|
|
|
CPlayerPool * GetPlayerPool() { return m_pPools->pPlayerPool; };
|
|
|
|
|
2024-02-21 19:04:26 +08:00
|
|
|
void ResetMapIcons();
|
|
|
|
void SetMapIcon(BYTE byteIndex, float fX, float fY, float fZ, BYTE byteIcon, DWORD dwColor, int iStyle);
|
|
|
|
void DisableMapIcon(BYTE byteIndex);
|
2023-11-14 22:58:51 +08:00
|
|
|
};
|