group2 0.1.0
CSE 125 Group 2
Loading...
Searching...
No Matches
PlayerRosterEvent Struct Reference

Server-authored join/leave notification for in-progress matches. More...

#include <RosterEvent.hpp>

Collaboration diagram for PlayerRosterEvent:
[legend]

Public Attributes

RosterEventType type = RosterEventType::PlayerJoined
 Join/leave discriminator.
ClientId id {-1}
 Client that joined or left.
char name [32] = {}
 Null-terminated display name when available.

Detailed Description

Server-authored join/leave notification for in-progress matches.

Sent as the payload of PacketType::ROSTER_UPDATE. The fixed-size name keeps the packet trivially copyable; clients fall back to ClientId if the name is empty or the replicated entity has already disappeared.

Member Data Documentation

◆ id

ClientId PlayerRosterEvent::id {-1}

Client that joined or left.

◆ name

char PlayerRosterEvent::name[32] = {}

Null-terminated display name when available.

◆ type

Join/leave discriminator.


The documentation for this struct was generated from the following file: