scroll.server/crates/game-service
WiseDev dfdcc3072a stop a battle that has already been decided
the hook showed a battle at tick 4177 - two hundred and eight seconds of
a hundred and eighty second match - sitting at three crowns to nil with
the player holding no towers at all. advance_to never asked whether the
battle was over, so the clock ran past the end, the bot kept playing
cards, and the snapshots kept coming. anything the player put down after
that walked into an army that had been piling up for a minute, which is
what "my units do not spawn" actually looked like.

is_end_condition_matched was right all along - it reads the leaders and
the clock and says so. nothing called it. now the tick loop breaks on
it, and the harness walks a match to its end and checks the tick stops
moving.

two things ruled out while looking. the account ids are right: the
client reads its own as 0-5, finds itself at index 0 and takes the
bottom avatar, and the 0-0 lookups in the trace are it resolving the
bot. and "visitor" is cosmetic - getHomeTeamIndex defaults to 1 when
both avatars share an arena, which ours do.
2026-08-23 18:10:25 +03:00
..
src stop a battle that has already been decided 2026-08-23 18:10:25 +03:00
tests stop a battle that has already been decided 2026-08-23 18:10:25 +03:00
Cargo.toml move players and accounts into postgres 2026-08-23 08:40:13 +03:00