|
|
@@ -1758,6 +1758,7 @@ function testClick(event) { |
|
|
testCtx.resetTransform(); |
|
|
testCtx.resetTransform(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
testCtx.translate(actualW/2, actualH/2); |
|
|
testCtx.translate(actualW/2, actualH/2); |
|
|
testCtx.rotate(angle); |
|
|
testCtx.rotate(angle); |
|
|
testCtx.translate(-actualW/2, -actualH/2); |
|
|
testCtx.translate(-actualW/2, -actualH/2); |
|
|
@@ -4683,6 +4684,7 @@ function renderToCanvas() { |
|
|
|
|
|
|
|
|
ctx.save(); |
|
|
ctx.save(); |
|
|
ctx.resetTransform(); |
|
|
ctx.resetTransform(); |
|
|
|
|
|
ctx.scale(window.devicePixelRatio, window.devicePixelRatio) |
|
|
ctx.translate(x, y); |
|
|
ctx.translate(x, y); |
|
|
ctx.rotate(entity.rotation); |
|
|
ctx.rotate(entity.rotation); |
|
|
ctx.drawImage(img, -xSize/2, -ySize/2, xSize, ySize); |
|
|
ctx.drawImage(img, -xSize/2, -ySize/2, xSize, ySize); |
|
|
|