nil_payload/request/
round.rs1use bon::Builder;
5use nil_core::world::config::WorldId;
6use serde::{Deserialize, Serialize};
7
8#[derive(Builder, Clone, Debug, Deserialize, Serialize)]
9#[serde(rename_all = "camelCase")]
10#[cfg_attr(feature = "typescript", derive(ts_rs::TS))]
11#[cfg_attr(feature = "typescript", ts(export))]
12pub struct GetRoundRequest {
13 #[builder(start_fn, into)]
14 pub world: WorldId,
15}
16
17#[derive(Builder, Clone, Debug, Deserialize, Serialize)]
18#[serde(rename_all = "camelCase")]
19#[cfg_attr(feature = "typescript", derive(ts_rs::TS))]
20#[cfg_attr(feature = "typescript", ts(export))]
21pub struct SetPlayerReadyRequest {
22 #[builder(start_fn, into)]
23 pub world: WorldId,
24 pub is_ready: bool,
25}
26
27#[derive(Builder, Clone, Debug, Deserialize, Serialize)]
28#[serde(rename_all = "camelCase")]
29#[cfg_attr(feature = "typescript", derive(ts_rs::TS))]
30#[cfg_attr(feature = "typescript", ts(export))]
31pub struct StartRoundRequest {
32 #[builder(start_fn, into)]
33 pub world: WorldId,
34}