The r-type_client program: scenes, inputs, network client and backend adapters (src/Client).
More...
|
| enum class | rtype::Action : uint32_t {
Action::NoneAction = 0
, Action::Up = 1 << 0
, Action::Down = 1 << 1
, Action::Left = 1 << 2
,
Action::Right = 1 << 3
, Action::Shoot = 1 << 4
, Action::Confirm = 1 << 5
} |
| | Client actions, one bit of InputState::actionMask each. More...
|
| |
| enum class | rtype::client::NetworkEventType { NetworkEventType::Connected
, NetworkEventType::Rejected
, NetworkEventType::Disconnected
, NetworkEventType::Message
} |
| | Kind of event produced by the network client. More...
|
| |
| enum class | rtype::client::SceneType { SceneType::Menu
, SceneType::Connection
, SceneType::Game
} |
| | Identifiers of the client scenes. More...
|
| |
The r-type_client program: scenes, inputs, network client and backend adapters (src/Client).
◆ ReplicationPayload
Initial value:
std::variant<protocol::CreateEntityPayload, protocol::DestroyEntityPayload,
protocol::SnapshotPayload>
Decoded replication message.
◆ Action
Client actions, one bit of InputState::actionMask each.
| Enumerator |
|---|
| NoneAction | No action.
|
| Up | Move up.
|
| Down | Move down.
|
| Left | Move left.
|
| Right | Move right.
|
| Shoot | Shoot.
|
| Confirm | Validate a menu.
|
◆ NetworkEventType
Kind of event produced by the network client.
| Enumerator |
|---|
| Connected | The server sent Welcome.
|
| Rejected | The server sent Rejected.
|
| Disconnected | The connection was closed.
|
| Message | A message that is not a replication message.
|
◆ SceneType
Identifiers of the client scenes.
| Enumerator |
|---|
| Menu | Title screen.
|
| Connection | Handshake with the server.
|
| Game | In game.
|
◆ hasAction()
| bool rtype::Input::hasAction |
( |
uint32_t | engineMask, |
|
|
Action | action ) |
|
nodiscardconstexpr |
Tells whether an action is active in a mask.
- Parameters
-
| engineMask | Action mask of the frame. |
| action | Action to test. |
- Returns
- True if the action bit is set.