From 572fc1b40b4cc10ad36117f9c5cf1106edc5ce2d Mon Sep 17 00:00:00 2001 From: Nathan Date: Sun, 13 Oct 2024 13:29:54 +0100 Subject: [PATCH] Add untapCard helper --- public/board.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/public/board.js b/public/board.js index 72534cd..02acb6d 100644 --- a/public/board.js +++ b/public/board.js @@ -758,6 +758,10 @@ class Board{ cardStatus[itemKey] = 'tapped'; // Do any other 'on tap' effects, etc. in the future } + untapCard(itemKey){ + cardStatus[itemKey] = null; + // Do any other 'on tap' effects, etc. in the future + } remainingShieldCount(playerId){ return getCurrentPositionAndLength('shield', playerId)[1]; } @@ -1045,7 +1049,7 @@ function untapZone(elementFrom, playerFrom){ // Just basic, if tapped, untap logic // See why the loop shouldn't need re-adding each time? if(cardStatus[itemKey] == 'tapped'){ - cardStatus[itemKey] = null; + board.untapCard(itemKey); } } }