From 2223c78338d21acfe58acf1363794dd0a4e34736 Mon Sep 17 00:00:00 2001 From: Kyle <41976328+ImKyle4815@users.noreply.github.com> Date: Thu, 31 Oct 2019 16:08:20 -0700 Subject: [PATCH] Update life.js --- data/site/other/life/life.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/data/site/other/life/life.js b/data/site/other/life/life.js index df9f1c26..44a2766e 100644 --- a/data/site/other/life/life.js +++ b/data/site/other/life/life.js @@ -1,6 +1,7 @@ //============================================// // Card Conjurer, by Kyle Burton // //============================================// +console.log("1.0") //define variables var playerCount, startingLifeTotal, firstPlayerWide = false, lastPlayerWide = false, playerList = [], rowHeight = 0, columnWidth = 0, rowCount = 0, isFullscreen = true, mouseClickId = 0, noSleep = new NoSleep(), canEnableNoSleep = false //Setup the enabler for no sleep @@ -77,10 +78,15 @@ function startGame() { if (playerCount == 2 || playerCount == 4) { rowCount -= 1 } + console.log("Row count: " + rowCount) if (isFullscreen) { rowHeight = screen.height / rowCount - 2 + console.log("Full screen, rowHeight: " + rowHeight) + console.log("screen.height: " + screen.height) } else { rowHeight = window.innerHeight / rowCount - 2 + console.log("Not full screen, rowHeight: " + rowHeight) + console.log("window.innerHeight: " + window.innerHeight) } //Now that all the player boxes are made, they must be configured for (var i = 1; i <= playerCount; i++) {