From 4331af9ee07cdec9ba78987cc248936e00a4f8ee Mon Sep 17 00:00:00 2001
From: Kyle <41976328+ImKyle4815@users.noreply.github.com>
Date: Sun, 25 Nov 2018 19:30:37 -0800
Subject: [PATCH] rotation
---
data/scripts/main.js | 2 ++
index.html | 2 ++
2 files changed, 4 insertions(+)
diff --git a/data/scripts/main.js b/data/scripts/main.js
index ac2f201f..23203162 100644
--- a/data/scripts/main.js
+++ b/data/scripts/main.js
@@ -441,12 +441,14 @@ function createBorder() {
//Draw card art
function drawPicture() {
//scales the card art and draws it
+ card.rotate(document.getElementById("imageRotation").value * Math.PI / 180);
var imageScale = document.getElementById("imageSize").value * 0.01
var imageLeftShift = parseInt(document.getElementById("imageLeft").value)
var imageUpShift = parseInt(document.getElementById("imageUp").value)
if (imgArt.width > 0) {
card.drawImage(imgArt, artX - imageLeftShift, artY - imageUpShift, imgArt.width * imageScale, imgArt.height * imageScale)
}
+ card.rotate(document.getElementById("imageRotation").value * Math.PI / -180);
}
//Draw the set symbol
diff --git a/index.html b/index.html
index 89103a7d..26e3d7bb 100644
--- a/index.html
+++ b/index.html
@@ -227,6 +227,8 @@
Image Up
+ Image Rotation
+