summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2024-11-24 12:56:45 +0100
committerTor Andersson <tor@ccxvii.net>2024-11-24 12:56:45 +0100
commit8e34f19c0147ef569db9518bd3459256855e5a0e (patch)
treeb2ab6092bab557e12c661b79ebf310898f940bf9
parentbe34836e93d0456b6d1651386260c188bb2f7e4c (diff)
downloadhammer-of-the-scots-8e34f19c0147ef569db9518bd3459256855e5a0e.tar.gz
Add dont_snap callback to prevent extra snapshots during card selection.
-rw-r--r--rules.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/rules.js b/rules.js
index 319f1a0..5a8c9af 100644
--- a/rules.js
+++ b/rules.js
@@ -3173,7 +3173,11 @@ function observer_hand() {
return hand
}
-exports.is_checkpoint = (a, b) => a.turn !== b.turn
+exports.dont_snap = function(state) {
+ if (state.state === "play_card" && state.active !== BOTH)
+ return true
+ return false
+}
exports.view = function(state, current) {
game = state