diff options
author | pommicket <pommicket@gmail.com> | 2024-08-10 21:07:21 -0400 |
---|---|---|
committer | pommicket <pommicket@gmail.com> | 2024-08-10 21:10:23 -0400 |
commit | 8ad005478a0dfcb187bb1ba65668977ae8ef4cf2 (patch) | |
tree | 9973b40c23639f2de6adab5dd8e45365012d3955 /game.js | |
parent | 24564afb32d2fd65c3d39d1114764bda831d1563 (diff) |
nicer starting positions
Diffstat (limited to 'game.js')
-rw-r--r-- | game.js | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -379,10 +379,10 @@ window.addEventListener('load', function () { } let nibTypeIndex = 0; if (playArea.clientWidth / puzzleWidth < playArea.clientHeight / puzzleHeight) { - pieceWidth = 0.5 * playArea.clientWidth / puzzleWidth; + pieceWidth = 0.6 * playArea.clientWidth / puzzleWidth; pieceHeight = pieceWidth * (puzzleWidth / puzzleHeight) * (image.height / image.width); } else { - pieceHeight = 0.5 * playArea.clientHeight / puzzleHeight; + pieceHeight = 0.6 * playArea.clientHeight / puzzleHeight; pieceWidth = pieceHeight * (puzzleHeight / puzzleWidth) * (image.width / image.height); } nibSize = Math.min(pieceWidth / 4, pieceHeight / 4); |