Bomberman Multiplayer
Authoritative multiplayer networking layer for Bomberman.
Loading...
Searching...
No Matches
ServerFlow.h
Go to the documentation of this file.
1
7#ifndef BOMBERMAN_SERVERFLOW_H
8#define BOMBERMAN_SERVERFLOW_H
9
10#include <cstdint>
11#include <optional>
12
13namespace bomberman::server
14{
15 struct ServerState;
16
18 void resetRoundRuntimeToLobby(ServerState& state);
19
21 void handleLobbyReadyStateChanged(ServerState& state);
22
24 void refreshServerFlowDiagnostics(ServerState& state);
25
27 void handleAcceptedPlayerJoined(ServerState& state);
28
30 bool beginMatchBootstrap(ServerState& state);
31
33 void advanceServerFlow(ServerState& state);
34
36 void markPlayerLoadedForCurrentMatch(ServerState& state, uint8_t playerId);
37
39 void handleAcceptedPlayerReleased(ServerState& state, uint8_t playerId);
40
42 void beginEndOfMatch(ServerState& state,
43 std::optional<uint8_t> winnerPlayerId,
44 bool draw,
45 uint8_t activePlayerCount,
46 uint8_t alivePlayerCount);
47} // namespace bomberman::server
48
49#endif // BOMBERMAN_SERVERFLOW_H
Authoritative dedicated-server state, match flow, and fixed-tick simulation support.
Definition ServerBombs.cpp:21
void resetRoundRuntimeToLobby(ServerState &state)
Resets round-scoped state and returns to the lobby.
Definition ServerLobbyFlow.cpp:271
bool beginMatchBootstrap(ServerState &state)
Starts match bootstrap from a validated lobby countdown commit.
Definition ServerLobbyFlow.cpp:329
void handleLobbyReadyStateChanged(ServerState &state)
Reacts to one lobby ready-state change.
Definition ServerLobbyFlow.cpp:286
void handleAcceptedPlayerReleased(ServerState &state, uint8_t playerId)
Updates flow state after one accepted player disconnects.
Definition ServerLobbyFlow.cpp:432
void handleAcceptedPlayerJoined(ServerState &state)
Applies the lobby participant-change policy after one accepted player joins.
Definition ServerLobbyFlow.cpp:319
void beginEndOfMatch(ServerState &state, std::optional< uint8_t > winnerPlayerId, bool draw, uint8_t activePlayerCount, uint8_t alivePlayerCount)
Commits end-of-match state for the current round.
Definition ServerMatchFlow.cpp:88
void refreshServerFlowDiagnostics(ServerState &state)
Refreshes coarse server-flow diagnostics.
Definition ServerFlow.cpp:32
void advanceServerFlow(ServerState &state)
Advances non-gameplay flow state.
Definition ServerFlow.cpp:40
void markPlayerLoadedForCurrentMatch(ServerState &state, uint8_t playerId)
Records one match-loaded acknowledgement.
Definition ServerLobbyFlow.cpp:408