From 9666676766bf21364f4fc4d0d1d336e72f2a91b4 Mon Sep 17 00:00:00 2001 From: historia <[not public]> Date: Tue, 6 Oct 2026 12:57:23 -0400 Subject: refactor: split casino.go, dedup helpers, remove audit docs --- internal/game/exit_migrate.go | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'internal/game/exit_migrate.go') diff --git a/internal/game/exit_migrate.go b/internal/game/exit_migrate.go index 4edab95..4f5dd72 100644 --- a/internal/game/exit_migrate.go +++ b/internal/game/exit_migrate.go @@ -25,6 +25,15 @@ func rewritePlayerRoomIDs(p *player.Player, idMap map[int]int) bool { if world.RemapInt(idMap, &p.RoomID) { changed = true } + // A multi-tick move or a stashed flee escape keeps its destination in + // MoveTarget/EscapeTarget; remap them too or completeMove will assign a + // pre-migration room ID with no existence check. + if world.RemapInt(idMap, &p.MoveTarget) { + changed = true + } + if world.RemapInt(idMap, &p.EscapeTarget) { + changed = true + } if p.PendingSequence != nil && p.PendingSequence.RoomID != 0 && world.RemapInt(idMap, &p.PendingSequence.RoomID) { changed = true } -- cgit v1.2.3