Room updates are the reliable event lane: submit named actions, then poll for broadcasts and pending requests. Keep the returned cursor so each client sees every update exactly once, across reconnects.
Methods for data synchronization between players
public Task<UpdatePlayersResponse> UpdatePlayersAsync<T>(string playerToken, UpdatePlayers<T> request, CancellationToken ct = default)
Sends updates to specific players or all players. Uses typed UpdatePlayers parameter.
public Task<PollUpdatesResponse> PollUpdatesAsync(string playerToken, PollUpdates request, CancellationToken ct = default)
Polls for updates from specific source players. Use PollUpdates request object to specify from_players, from_players_ids, and lastUpdate.
Room updates are the durable state lane: send writes a typed update — position, loadout, ready flag, board state — addressed to a target set, and it persists for late joiners instead of evaporating like an ephemeral message. Latest value wins: write the current state, not a history.
Poll reads updates since the last cursor you stored, optionally filtered by source players. Keep the returned cursor per client so every update is delivered exactly once — across reconnects and rejoins, which is what makes the lane reliable.