From b34b2a5b8d118974502c015912e1ed67fa6965b0 Mon Sep 17 00:00:00 2001 From: metamuffin Date: Tue, 21 Oct 2025 00:18:09 +0200 Subject: more debug events, bots now broken --- server/bot/src/algos/customer.rs | 4 ++-- server/bot/src/algos/frank.rs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'server/bot/src/algos') diff --git a/server/bot/src/algos/customer.rs b/server/bot/src/algos/customer.rs index fa10410b..fe665f47 100644 --- a/server/bot/src/algos/customer.rs +++ b/server/bot/src/algos/customer.rs @@ -175,7 +175,7 @@ impl CustomerState { }) { *self = CustomerState::New; - } else if path.is_stuck() { + } else if path.is_stuck(3.) { if let Some(path) = find_path(game, pos.as_ivec2(), *origin) { *self = CustomerState::Exiting { path }; } @@ -392,7 +392,7 @@ impl CustomerState { } } CustomerState::Exiting { path } => { - if path.is_done() || path.is_stuck() { + if path.is_done() || path.is_stuck(3.) { debug!("{me:?} -> leave"); *self = CustomerState::Exited } else { diff --git a/server/bot/src/algos/frank.rs b/server/bot/src/algos/frank.rs index eeee3b61..a02b0112 100644 --- a/server/bot/src/algos/frank.rs +++ b/server/bot/src/algos/frank.rs @@ -76,7 +76,7 @@ impl BotAlgo for Frank { if let Some(path) = &mut self.path { let direction = path.next_direction(pos, dt); - if path.is_stuck() { + if path.is_stuck(3.) { self.path = None; } else if path.is_done() { self.path = None; -- cgit v1.3