[bot] Rename CNPCMode to CGameMode

This commit is contained in:
RD42 2024-01-19 23:19:26 +08:00
parent ec63982f4d
commit 00b4c91686
8 changed files with 35 additions and 33 deletions

View File

@ -227,18 +227,18 @@
<File
RelativePath=".\bot.rc">
</File>
<File
RelativePath=".\gamemodes.cpp">
</File>
<File
RelativePath=".\gamemodes.h">
</File>
<File
RelativePath=".\main.cpp">
</File>
<File
RelativePath=".\main.h">
</File>
<File
RelativePath=".\npcmode.cpp">
</File>
<File
RelativePath=".\npcmode.h">
</File>
<File
RelativePath=".\resource.h">
</File>

8
bot/gamemodes.cpp Normal file
View File

@ -0,0 +1,8 @@
#include "main.h"
CGameMode::CGameMode()
{
field_68 = 0;
field_69 = 0;
}

18
bot/gamemodes.h Normal file
View File

@ -0,0 +1,18 @@
#ifndef SAMPNPC_GAMEMODES_H
#define SAMPNPC_GAMEMODES_H
class CGameMode // size: 110
{
private:
char _gap0[104];
char field_68;
char field_69;
float field_6A;
public:
CGameMode();
};
#endif

View File

@ -37,7 +37,7 @@ typedef unsigned short PLAYERID;
typedef unsigned short VEHICLEID;
#include "scrtimers.h"
#include "npcmode.h"
#include "gamemodes.h"
#include "net/netrpc.h"
#include "net/playerpool.h"

View File

@ -80,7 +80,7 @@ void CNetGame::Init(PCHAR szHostOrIp, int iPort,
strncpy(m_szHostOrIp, szHostOrIp, sizeof(m_szHostOrIp));
m_iPort = iPort;
m_pNPCMode = new CNPCMode();
m_pGameMode = new CGameMode();
m_pScriptTimers = new CScriptTimers();
// Setup player pool

View File

@ -43,7 +43,7 @@ private:
char m_szHostOrIp[128];
int m_iPort;
CNPCMode* m_pNPCMode;
CGameMode* m_pGameMode;
CScriptTimers* m_pScriptTimers;
public:

View File

@ -1,12 +0,0 @@
// Now the question is, is this called CGameMode or something else?
// It is basically the same as what the server has with minor differences
#include "npcmode.h"
CNPCMode::CNPCMode()
{
// TODO: CNPCMode::CNPCMode W: 0041A9C0 L: 080A940C
field_68 = 0;
field_69 = 0;
}

View File

@ -1,12 +0,0 @@
class CNPCMode // size: 110
{
private:
char _gap0[104];
char field_68;
char field_69;
float field_6A;
public:
CNPCMode();
};