aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--server/bot/src/algos/customer.rs10
-rw-r--r--server/protocol/src/lib.rs2
-rw-r--r--server/src/entity/mod.rs9
3 files changed, 15 insertions, 6 deletions
diff --git a/server/bot/src/algos/customer.rs b/server/bot/src/algos/customer.rs
index 2e0a45b4..716897f7 100644
--- a/server/bot/src/algos/customer.rs
+++ b/server/bot/src/algos/customer.rs
@@ -132,6 +132,11 @@ impl BotAlgo for Customer {
*self = Customer::Exiting { path };
BotInput {
extra: vec![
+ PacketS::Communicate {
+ message: None,
+ timeout: Some(0.),
+ player: me,
+ },
PacketS::ApplyScore(Score {
points: -1,
demands_failed: 1,
@@ -179,6 +184,11 @@ impl BotAlgo for Customer {
BotInput {
extra: vec![
PacketS::Communicate {
+ message: None,
+ timeout: Some(0.),
+ player: me,
+ },
+ PacketS::Communicate {
message: Some(Message::Effect("satisfied".to_string())),
timeout: None,
player: me,
diff --git a/server/protocol/src/lib.rs b/server/protocol/src/lib.rs
index 7b3b39a5..a55eabe2 100644
--- a/server/protocol/src/lib.rs
+++ b/server/protocol/src/lib.rs
@@ -231,7 +231,7 @@ pub enum Menu {
Score(Score),
}
-#[derive(Debug, Clone, Copy, Serialize, Deserialize, Encode, Decode)]
+#[derive(Debug, Clone, Copy, Serialize, Deserialize, Encode, Decode, Default)]
pub struct MessageTimeout {
pub remaining: f32,
pub initial: f32,
diff --git a/server/src/entity/mod.rs b/server/src/entity/mod.rs
index 20370d0c..d8fa5654 100644
--- a/server/src/entity/mod.rs
+++ b/server/src/entity/mod.rs
@@ -55,14 +55,13 @@ pub trait Entity {
// macro_rules! entities {
// ($($e:ident),*) => {
-// #[derive(Debug)]
-// pub enum Entity { $($e($e)),* }
-// impl EntityT for Entity {
+// pub enum DynEntity { $($e($e)),* }
+// impl Entity for DynEntity {
// fn tick(&mut self, c: EntityContext<'_>) -> Result<()> {
-// match self { $(Entity::$e(x) => x.tick(c)),*, }
+// match self { $(DynEntity::$e(x) => x.tick(c)),*, }
// }
// fn destructor(&mut self, c: EntityContext<'_>) {
-// match self { $(Entity::$e(x) => x.destructor(c)),*, }
+// match self { $(DynEntity::$e(x) => x.destructor(c)),*, }
// }
// }
// };