diff options
Diffstat (limited to 'tracker/AdminServer/mapslist.h')
| -rw-r--r-- | tracker/AdminServer/mapslist.h | 70 |
1 files changed, 70 insertions, 0 deletions
diff --git a/tracker/AdminServer/mapslist.h b/tracker/AdminServer/mapslist.h new file mode 100644 index 0000000..511fe23 --- /dev/null +++ b/tracker/AdminServer/mapslist.h @@ -0,0 +1,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
\ No newline at end of file |