diff options
author | metamuffin <metamuffin@disroot.org> | 2024-12-25 19:37:20 +0100 |
---|---|---|
committer | metamuffin <metamuffin@disroot.org> | 2024-12-25 19:37:20 +0100 |
commit | bd74a4e0c0e4e42717c2931eab3febfae219ac9c (patch) | |
tree | 30d6dc91921aab9a8ffd271901d8122891560a65 /server/protocol/src/lib.rs | |
parent | 462bc5a62f24a35e05d6a171566495e2641583a8 (diff) | |
download | hurrycurry-bd74a4e0c0e4e42717c2931eab3febfae219ac9c.tar hurrycurry-bd74a4e0c0e4e42717c2931eab3febfae219ac9c.tar.bz2 hurrycurry-bd74a4e0c0e4e42717c2931eab3febfae219ac9c.tar.zst |
variable hand count
Diffstat (limited to 'server/protocol/src/lib.rs')
-rw-r--r-- | server/protocol/src/lib.rs | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/server/protocol/src/lib.rs b/server/protocol/src/lib.rs index 5c7ddeb5..74d463a1 100644 --- a/server/protocol/src/lib.rs +++ b/server/protocol/src/lib.rs @@ -72,11 +72,8 @@ pub struct RecipeIndex(pub usize); pub struct DemandIndex(pub usize); #[derive(Debug, Clone, Copy, Serialize, Deserialize, Encode, Decode, PartialEq, Eq, Hash)] -#[serde(rename_all = "snake_case")] -pub enum Hand { - Left, - Right, -} +#[serde(transparent)] +pub struct Hand(pub usize); #[derive(Debug, Clone, Serialize, Deserialize, Encode, Decode)] pub struct MapMetadata { @@ -105,6 +102,7 @@ pub struct Gamedata { pub bot_algos: Vec<String>, pub recipes: Vec<Recipe>, pub demands: Vec<Demand>, + pub hand_count: usize, } #[derive(Debug, Clone, Serialize, Deserialize, Encode, Decode)] |