iw4x-client/src/Components/Modules/Bots.hpp
2023-04-16 13:01:58 +02:00

42 lines
1.1 KiB
C++

#pragma once
namespace Components
{
class Bots : public Component
{
public:
Bots();
static void SV_DirectConnect_Full_Check();
private:
using botData = std::pair< std::string, std::string>;
static std::vector<botData> BotNames;
static const Game::dvar_t* sv_randomBotNames;
static const Game::dvar_t* sv_replaceBots;
static void RandomizeBotNames();
static std::string TruncBotString(const std::string& input, std::size_t length);
static void LoadBotNames();
static int BuildConnectString(char* buffer, const char* connectString, int num, int, int protocol, int checksum, int statVer, int statStuff, int port);
static void Spawn(unsigned int count);
static void GScr_isTestClient(Game::scr_entref_t entref);
static void AddScriptMethods();
static void BotAiAction(Game::client_t* cl);
static void SV_BotUserMove_Hk();
static void G_SelectWeaponIndex(int clientNum, int iWeaponIndex);
static void G_SelectWeaponIndex_Hk();
static int SV_GetClientPing_Hk(int clientNum);
static bool IsFull();
static void CleanBotArray();
};
}