This commit is contained in:
2025-03-30 22:43:41 +02:00
parent 0271b56542
commit f4b58fb67e
6 changed files with 99 additions and 18 deletions

View File

@@ -91,7 +91,7 @@ bool PiecesFiles::loadPieces(int polyominoSize, std::vector<Piece>& pieces, std:
char positionByte;
for (int i = 0; i < polyominoSize; i++) {
piecesFile.get(positionByte);
int x = (positionByte & xMask) >> 4;
int x = ((unsigned char) positionByte & xMask) >> 4;
int y = positionByte & yMask;
piecePositions.insert(Position{x, y});
}