iw4x-client/src/Components/Modules/ServerInfo.hpp

44 lines
761 B
C++
Raw Normal View History

2016-01-07 20:20:55 -05:00
namespace Components
{
class ServerInfo : public Component
{
public:
ServerInfo();
2016-08-15 10:40:30 -04:00
~ServerInfo();
#ifdef DEBUG
2016-01-07 20:20:55 -05:00
const char* GetName() { return "ServerInfo"; };
2016-08-15 10:40:30 -04:00
#endif
2016-01-07 20:20:55 -05:00
2016-06-05 11:34:55 -04:00
static Utils::InfoString GetInfo();
2016-01-07 20:20:55 -05:00
private:
2016-06-30 13:38:48 -04:00
class Container
2016-01-07 20:20:55 -05:00
{
2016-06-30 13:38:48 -04:00
public:
class Player
2016-01-07 20:20:55 -05:00
{
2016-06-30 13:38:48 -04:00
public:
2016-01-07 20:20:55 -05:00
int Ping;
int Score;
std::string Name;
};
2016-01-10 06:25:31 -05:00
unsigned int CurrentPlayer;
2016-01-07 20:20:55 -05:00
std::vector<Player> PlayerList;
Network::Address Target;
};
static Container PlayerContainer;
static void ServerStatus();
2016-01-10 06:25:31 -05:00
static unsigned int GetPlayerCount();
static const char* GetPlayerText(unsigned int index, int column);
static void SelectPlayer(unsigned int index);
2016-03-14 13:29:45 -04:00
static void DrawScoreboardInfo(void* a1);
static void DrawScoreboardStub();
2016-01-07 20:20:55 -05:00
};
}