summaryrefslogtreecommitdiff
path: root/tracker/AdminServer/serverping.h
diff options
context:
space:
mode:
authorFluorescentCIAAfricanAmerican <[email protected]>2020-04-22 12:56:21 -0400
committerFluorescentCIAAfricanAmerican <[email protected]>2020-04-22 12:56:21 -0400
commit3bf9df6b2785fa6d951086978a3e66f49427166a (patch)
tree2c0f1f0c63c4832882bc93814ebd2c2b1c6224e5 /tracker/AdminServer/serverping.h
downloadarchived-source-engine-2018-hl2-src-master.tar.xz
archived-source-engine-2018-hl2-src-master.zip
Diffstat (limited to 'tracker/AdminServer/serverping.h')
-rw-r--r--tracker/AdminServer/serverping.h55
1 files changed, 55 insertions, 0 deletions
diff --git a/tracker/AdminServer/serverping.h b/tracker/AdminServer/serverping.h
new file mode 100644
index 0000000..43d8e74
--- /dev/null
+++ b/tracker/AdminServer/serverping.h
@@ -0,0 +1,55 @@
+//========= Copyright Valve Corporation, All rights reserved. ============//
+//
+// Purpose: defines a RCon class used to send rcon commands to remote servers
+//
+// $NoKeywords: $
+//=============================================================================
+
+#ifndef SERVERPING_H
+#define SERVERPING_H
+#ifdef _WIN32
+#pragma once
+#endif
+
+#include "server.h"
+#include "netadr.h"
+
+class CSocket;
+class IResponse;
+
+
+class CServerPing
+{
+
+public:
+
+ CServerPing(IResponse *target,serveritem_t &server);
+ ~CServerPing();
+
+ // send a ping to the server
+ void Query();
+
+ void Refresh();
+
+ bool IsRefreshing();
+ serveritem_t &GetServer();
+ void RunFrame();
+ bool Refreshed();
+
+ void UpdateServer(float recvTime);
+
+private:
+
+ serveritem_t m_Server;
+ CSocket *m_pQuery; // Game server query socket
+
+ IResponse *m_pResponseTarget;
+
+ bool m_bIsRefreshing;
+ float m_fSendTime;
+ bool m_bRefreshed;
+
+};
+
+
+#endif // SERVERPING_H \ No newline at end of file