From c866377681fc1dd57cb21ea154200fd68c1d517f Mon Sep 17 00:00:00 2001 From: Mike Thomas Date: Mon, 23 Jan 2006 19:09:45 +0000 Subject: [PATCH] Bugfix - This MAY be the elusive sync bug(s). Puzzle controller queues progress events, then sends them periodicially on a tick. The round-id at the time of the tick is used to make sure stale events aren't sent. BUT, the queue never used to be cleared when the round changed, so stale events already in the queue could still be sent. Now clearing queue on round change. git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3816 542714f4-19e9-0310-aa3c-eee0fc999fb1 --- src/java/com/threerings/puzzle/client/PuzzleController.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/java/com/threerings/puzzle/client/PuzzleController.java b/src/java/com/threerings/puzzle/client/PuzzleController.java index 618cb4d98..5696df831 100644 --- a/src/java/com/threerings/puzzle/client/PuzzleController.java +++ b/src/java/com/threerings/puzzle/client/PuzzleController.java @@ -360,6 +360,11 @@ public abstract class PuzzleController extends GameController super.attributeChanged(event); break; } + } else if (event.getName().equals(PuzzleObject.ROUND_ID)) { + // Need to clear out stale events. If we don't, we could send + // events that claim to be from the new round that are actually + // from the old round. + _events.clear(); } }