Implement shared 7-bag piece sequence
- Add generatePieceBag() and createPieceQueue() for 7-bag system - Add pieceQueue and playerSequenceIndex to lobby state - Modify spawnPiece() to consume from shared queue per player - Update player-hold handler to manage sequence index on hold - Add sequenceIndex to state updates for tracking - Update client loadState() to receive sequenceIndex Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -366,6 +366,7 @@ class TetrisGame {
|
||||
this.level = state.level;
|
||||
this.gameOver = state.gameOver;
|
||||
this.eliminated = state.eliminated;
|
||||
this.sequenceIndex = state.sequenceIndex || 0;
|
||||
this.dropInterval = Math.max(100, 1000 - (this.level - 1) * 100);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user