mirror of
https://github.com/cmclark00/tetris-3d.git
synced 2025-05-17 15:15:20 +01:00
Fix next piece preview not updating on mobile
This commit is contained in:
parent
71afcdee75
commit
3c5afc01c8
1 changed files with 4 additions and 3 deletions
|
@ -535,7 +535,8 @@ class Piece {
|
|||
} else {
|
||||
// If can't move down, lock the piece
|
||||
this.lock();
|
||||
p = randomPiece();
|
||||
// Replace with getNextPiece function call instead of direct assignment
|
||||
getNextPiece();
|
||||
p.calculateShadowY(); // Calculate shadow for new piece
|
||||
}
|
||||
|
||||
|
@ -652,8 +653,8 @@ class Piece {
|
|||
// Lock the piece
|
||||
this.lock();
|
||||
|
||||
// Get new piece
|
||||
p = randomPiece();
|
||||
// Replace with getNextPiece function call instead of direct assignment
|
||||
getNextPiece();
|
||||
|
||||
// Calculate shadow for new piece
|
||||
p.calculateShadowY();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue