Net message types
Network message wrappers for Source2 networking system.
This file defines strongly-typed wrappers around protobuf-based network messages used by the engine.
Messages are grouped into categories:
- net_* -> core networking
- clc_* -> client -> server
- svc_* -> server -> client
All classes inherit from CNetMessagePB.
Template parameters define message ID, protobuf type, group and flags.
Header source2mod/schema/netmessages.h
Inherits CNetMessagePB< PROTO_TYPE >
Fields
| Field | Type |
|---|---|
kMsgId | int32_t |
kSignonGroup | SignonGroup_t |
kBufType | NetChannelBufType_t |
kIsForServer | bool |
Methods
GetGroupName
static constexpr const char* GetGroupName();MyType_t
using MyType_t = CNetMessagePBTyped< ID, PROTO_TYPE, SIGNON, BUF_TYPE, IS_FOR_SERVER >;PBType_t
using PBType_t = PROTO_TYPE;Enums
SignonGroup_t
enum SignonGroup_t : int32_t| Name | Value |
|---|---|
SG_INVALID | -1 |
SG_GENERIC | 0 |
SG_LOCALPLAYER | 1 |
SG_OTHERPLAYER | 2 |
SG_ENTITIES | 3 |
SG_SOUNDS | 4 |
SG_EVENTS | 5 |
SG_VOICE | 6 |
SG_STRINGTABLE | 7 |
SG_MOVE | 8 |
SG_STRINGCMD | 9 |
SG_SIGNON | 10 |
SG_SYSTEM | 11 |
SG_DECALS | 12 |
SG_USERMSG | 13 |
SG_CLIENTMSG | 14 |
SG_SPAWNGROUPS | 15 |
SG_ENGINE | 16 |
SG_HLTVREPLAY | 17 |
SG_TOTAL | 18 |