1#ifndef ENGINE_SHARED_PROTOCOL_EX_H
2#define ENGINE_SHARED_PROTOCOL_EX_H
3
4#include <engine/shared/uuid_manager.h>
5
6class CMsgPacker;
7class CUnpacker;
8
9enum
10{
11 NETMSG_EX_INVALID = UUID_INVALID,
12 NETMSG_EX_UNKNOWN = UUID_UNKNOWN,
13
14 OFFSET_NETMSG_UUID = OFFSET_UUID,
15
16 __NETMSG_UUID_HELPER = OFFSET_NETMSG_UUID - 1,
17#define UUID(id, name) id,
18#include "protocol_ex_msgs.h"
19#undef UUID
20 OFFSET_TEEHISTORIAN_UUID,
21
22 UNPACKMESSAGE_ERROR = 0,
23 UNPACKMESSAGE_OK,
24 UNPACKMESSAGE_ANSWER,
25
26 SERVERCAP_CURVERSION = 5,
27 SERVERCAPFLAG_DDNET = 1 << 0,
28 SERVERCAPFLAG_CHATTIMEOUTCODE = 1 << 1,
29 SERVERCAPFLAG_ANYPLAYERFLAG = 1 << 2,
30 SERVERCAPFLAG_PINGEX = 1 << 3,
31 SERVERCAPFLAG_ALLOWDUMMY = 1 << 4,
32 SERVERCAPFLAG_SYNCWEAPONINPUT = 1 << 5,
33};
34
35void RegisterUuids(CUuidManager *pManager);
36bool NetworkExDefaultHandler(int *pId, CUuid *pUuid, CUnpacker *pUnpacker, CMsgPacker *pPacker, int Type);
37
38int UnpackMessageId(int *pId, bool *pSys, CUuid *pUuid, CUnpacker *pUnpacker, CMsgPacker *pPacker);
39
40#endif // ENGINE_SHARED_PROTOCOL_EX_H
41