Skip to content

Commit

Permalink
Fix pices scaling issue
Browse files Browse the repository at this point in the history
  • Loading branch information
tgass committed Jun 21, 2020
1 parent eb66db1 commit cd9114f
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/Macbeth/Wx/Game/Board.hs
Expand Up @@ -73,9 +73,10 @@ drawPieces = do
liftIO $ sequence_ $ drawPiece dc state <$> virtualPosition state
where
drawPiece :: DC a -> BoardState -> (Square, Piece) -> IO ()
drawPiece dc state (sq, piece) = drawBitmap dc
(pieceToBitmap (runtimeEnv state) (pieceSet $ boardConfig state) piece (pieceImgSize state))
(toPos' (squareSizePx state) sq (perspective state)) True []
drawPiece dc state (sq, piece) = do
let b = pieceToBitmap (runtimeEnv state) (pieceSet $ boardConfig state) piece (pieceImgSize state)
bitmapSetSize b $ Size (squareSizePx state) (squareSizePx state)
drawBitmap dc b (toPos' (squareSizePx state) sq (perspective state)) True []


drawSelectedSquare :: BoardT a
Expand Down

0 comments on commit cd9114f

Please sign in to comment.