summaryrefslogtreecommitdiff
path: root/utils/vmpi/messagemgr.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 /utils/vmpi/messagemgr.h
downloadarchived-source-engine-2018-hl2-src-master.tar.xz
archived-source-engine-2018-hl2-src-master.zip
Diffstat (limited to 'utils/vmpi/messagemgr.h')
-rw-r--r--utils/vmpi/messagemgr.h39
1 files changed, 39 insertions, 0 deletions
diff --git a/utils/vmpi/messagemgr.h b/utils/vmpi/messagemgr.h
new file mode 100644
index 0000000..cebbe76
--- /dev/null
+++ b/utils/vmpi/messagemgr.h
@@ -0,0 +1,39 @@
+//========= Copyright Valve Corporation, All rights reserved. ============//
+//
+// Purpose:
+//
+// $NoKeywords: $
+//=============================================================================//
+
+#ifndef MESSAGEMGR_H
+#define MESSAGEMGR_H
+#ifdef _WIN32
+#pragma once
+#endif
+
+
+#define MSGMGR_VERSION 52314
+#define MSGMGR_BROADCAST_PORT 22511
+
+#define MSGMGR_PACKETID_MSG 0
+#define MSGMGR_PACKETID_ANNOUNCE_PRESENCE 1 // followed by version # and port
+
+
+// IMessageMgr provides a simple interface apps can use to generate output. Apps
+// on the network can connect to the messagemgr to get its output and display it.
+class IMessageMgr
+{
+public:
+ virtual bool Init() = 0;
+ virtual void Term() = 0;
+
+ virtual void Print( const char *pMsg ) = 0;
+};
+
+
+// Get the message manager. It's a global singleton so this will always
+// return the same value (null if the manager can't initialize).
+IMessageMgr* GetMessageMgr();
+
+
+#endif // MESSAGEMGR_H