|
@@ -145,7 +145,7 @@ export default class GameLogic {
|
145
|
145
|
callback(this.#gridManager.getCurrentGrid());
|
146
|
146
|
}
|
147
|
147
|
this.#pressInInterval = setTimeout(() =>
|
148
|
|
- this.movePressedRepeat(false, callback, x, y),
|
|
148
|
+ this.movePressedRepeat(false, callback, x, y),
|
149
|
149
|
isInitial ? this.#autoRepeatActivationDelay : this.#autoRepeatDelay
|
150
|
150
|
);
|
151
|
151
|
}
|
|
@@ -166,7 +166,8 @@ export default class GameLogic {
|
166
|
166
|
getNextPiecesPreviews() {
|
167
|
167
|
let finalArray = [];
|
168
|
168
|
for (let i = 0; i < this.#nextPieces.length; i++) {
|
169
|
|
- finalArray.push(this.#gridManager.getEmptyGrid(4, 4));
|
|
169
|
+ const gridSize = this.#nextPieces[i].getCurrentShape().getCurrentShape()[0].length;
|
|
170
|
+ finalArray.push(this.#gridManager.getEmptyGrid(gridSize, gridSize));
|
170
|
171
|
this.#nextPieces[i].toGrid(finalArray[i], true);
|
171
|
172
|
}
|
172
|
173
|
|