Monopoly — Portage moderne
0.1.0
Portage moderne C/C++23 du Monopoly de 1999
Loading...
Searching...
No Matches
RuleConfiguration.hpp
Go to the documentation of this file.
1
#pragma once
2
3
#include "
Actions.hpp
"
4
#include "
RuleTypes.hpp
"
5
6
namespace
monopoly::rules::configuration
7
{
8
struct
AcceptanceUpdate
9
{
10
bool
optionsChanged
{};
11
bool
acceptanceChanged
{};
12
13
[[
nodiscard
]]
bool
restartNeeded
()
const
noexcept
14
{
15
return
optionsChanged
||
acceptanceChanged
;
16
}
17
};
18
19
void
clearAcceptConfiguration
(
GameState
&
state
)
noexcept
;
20
21
[[
nodiscard
]] AcceptanceUpdate
applyAcceptedConfiguration
(
22
GameState
&
state
,
23
const
actions::Message
& message);
24
25
[[
nodiscard
]]
bool
acceptedConfigurationMessage
(
26
const
GameOptions
& options,
27
PlayerNumber
fromPlayer,
28
bool
interim
,
29
actions::Message
& result);
30
31
[[
nodiscard
]]
actions::Message
proposedConfigurationMessage
(
32
const
GameState
&
state
);
33
}
Actions.hpp
index
unsigned index
Definition
ModernIBarSkin.cpp:25
RuleTypes.hpp
monopoly::rules::configuration
Definition
RuleConfiguration.cpp:8
monopoly::rules::configuration::proposedConfigurationMessage
actions::Message proposedConfigurationMessage(const GameState &state)
Definition
RuleConfiguration.cpp:91
monopoly::rules::configuration::clearAcceptConfiguration
void clearAcceptConfiguration(GameState &state) noexcept
Definition
RuleConfiguration.cpp:9
monopoly::rules::configuration::acceptedConfigurationMessage
bool acceptedConfigurationMessage(const GameOptions &options, PlayerNumber fromPlayer, bool interim, actions::Message &result)
Definition
RuleConfiguration.cpp:67
monopoly::rules::configuration::applyAcceptedConfiguration
AcceptanceUpdate applyAcceptedConfiguration(GameState &state, const actions::Message &message)
Definition
RuleConfiguration.cpp:28
monopoly::rules::PlayerNumber
std::uint8_t PlayerNumber
Definition
RuleTypes.hpp:12
monopoly::rules::state
const GameState & state()
Definition
RulesEngine.cpp:662
monopoly::actions::Message
Definition
Actions.hpp:125
monopoly::rules::GameOptions
Definition
RuleTypes.hpp:138
monopoly::rules::GameState
Definition
RuleTypes.hpp:259
monopoly::rules::configuration::AcceptanceUpdate
Definition
RuleConfiguration.hpp:9
monopoly::rules::configuration::AcceptanceUpdate::restartNeeded
bool restartNeeded() const noexcept
Definition
RuleConfiguration.hpp:13
monopoly::rules::configuration::AcceptanceUpdate::optionsChanged
bool optionsChanged
Definition
RuleConfiguration.hpp:10
monopoly::rules::configuration::AcceptanceUpdate::acceptanceChanged
bool acceptanceChanged
Definition
RuleConfiguration.hpp:11
RuleConfiguration.hpp
Generated by
1.9.8