blob: 511fe2326e34df6c10b9040e677c61c8ace9aa3f (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
|
//========= Copyright Valve Corporation, All rights reserved. ============//
//
// Purpose:
//
// $NoKeywords: $
//=============================================================================
#ifndef MAPSLIST_H
#define MAPSLIST_H
#ifdef _WIN32
#pragma once
#endif
#include "server.h"
#include "netadr.h"
#include "maps.h"
#include "rcon.h"
#include "utlvector.h"
#include "Iresponse.h"
class CSocket;
class IResponse;
class CMapsList: public IResponse
{
public:
CMapsList(IResponse *target,serveritem_t &server, const char *rconPassword,const char *mod);
~CMapsList();
// send an rcon command to a server
void SendQuery();
void Refresh();
bool IsRefreshing();
serveritem_t &GetServer();
void RunFrame();
void UpdateServer();
CUtlVector<Maps_t> *GetMapsList();
bool NewMapsList();
void ServerResponded();
// called when a server response has timed out
void ServerFailedToRespond();
void SetPassword(const char *newPass);
private:
serveritem_t m_Server;
CUtlVector<Maps_t> m_MapsList;
IResponse *m_pResponseTarget;
CRcon *m_pRcon;
char m_sMod[64];
bool m_bIsRefreshing;
bool m_bNewMapsList;
bool m_bRconFailed;
char m_szRconPassword[100];
};
#endif // MAPSLIST_H
|