From 04010047f10ea944402698f831013c27f1c3e57d Mon Sep 17 00:00:00 2001 From: Joël Simoneau Date: Thu, 10 Apr 2025 07:03:33 -0400 Subject: patch discard --- rules.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/rules.js b/rules.js index 8ac2e91..e1dbe25 100644 --- a/rules.js +++ b/rules.js @@ -252,7 +252,7 @@ exports.setup = function (seed, scenario, _options) { cavalry: Array(10).fill(AVAILABLE), deck: [], of_gods_and_kings: [null, null, 0], - discard: [], + // discard: [], order: [], cmd: { type: null, @@ -411,6 +411,10 @@ function end_card() { } function update_discard() { + if ("discard" in game === false) { + game.discard = [] + } + if (this_card() === 45) game.discard = [45] else if (this_card() === 46) -- cgit v1.2.3