From 38391cac2aa3145995ca6fecb8cde6a3e0bf2b25 Mon Sep 17 00:00:00 2001 From: Acamaeda Date: Wed, 21 Oct 2020 17:43:05 -0400 Subject: [PATCH] Fixed update function --- changelog.md | 3 +++ js/Demo/demoMod.js | 2 +- js/game.js | 6 +++--- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/changelog.md b/changelog.md index 0b38b9c..859d8bd 100644 --- a/changelog.md +++ b/changelog.md @@ -1,5 +1,8 @@ # The Modding Tree changelog: +### v2.1.3.1 - 10/21/20 +- Fixed the update function. + ### v2.1.3 - 10/21/20 - gainMult and gainExp are now optional. - Layer unlocking is now kept on reset. diff --git a/js/Demo/demoMod.js b/js/Demo/demoMod.js index 3baf90e..c3679b3 100644 --- a/js/Demo/demoMod.js +++ b/js/Demo/demoMod.js @@ -11,7 +11,7 @@ let modInfo = { // Set your version in num and name let VERSION = { - num: "2.1", + num: "2.1.3.1", name: " We should have thought of this sooner!", } diff --git a/js/game.js b/js/game.js index ae4ef4e..248a3c8 100644 --- a/js/game.js +++ b/js/game.js @@ -5,7 +5,7 @@ var gameEnded = false; // Don't change this const TMT_VERSION = { - tmtNum: "2.1.1", + tmtNum: "2.1.3.1", tmtName: "We should have thought of this sooner!" } @@ -289,14 +289,14 @@ function gameLoop(diff) { for (x = 0; x <= maxRow; x++){ for (item in TREE_LAYERS[x]) { let layer = TREE_LAYERS[x][item].layer - if (layers[layer].update) layers[layer].update(); + if (layers[layer].update) layers[layer].update(diff); } } for (row in OTHER_LAYERS){ for (item in OTHER_LAYERS[row]) { let layer = OTHER_LAYERS[row][item].layer - if (layers[layer].update) layers[layer].update(); + if (layers[layer].update) layers[layer].update(diff); } }