ddnet/src/engine/shared/global_uuid_manager.cpp
heinrich5991 5ae37e6c72 Add protocol extension with UUIDs
This system can easily be extended by independent authors without
collisions, something the old system with plain increasing integers did
not allow.

Do this by utilizing the previously unused message code `NETMSG_NULL`
which has a value of 0.

This works for engine and game messages, snapshot items and events.
2017-05-25 00:52:43 +02:00

15 lines
281 B
C++

#include "protocol_ex.h"
#include "uuid_manager.h"
#include <engine/uuid.h>
static CUuidManager CreateGlobalUuidManager()
{
CUuidManager Manager;
RegisterUuids(&Manager);
RegisterGameUuids(&Manager);
return Manager;
}
CUuidManager g_UuidManager = CreateGlobalUuidManager();