summaryrefslogtreecommitdiff
path: root/rules.js
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2023-04-15 15:48:41 +0200
committerTor Andersson <tor@ccxvii.net>2023-05-03 18:48:16 +0200
commitdf9b72408410a7d93bf4d4a1cc4c061223bcae3c (patch)
tree95542d1924c226094b4e95ffd842522b20678409 /rules.js
parentacd623b1af75bd540216684bf7f3f40b71bd3f38 (diff)
downloadandean-abyss-df9b72408410a7d93bf4d4a1cc4c061223bcae3c.tar.gz
Allow removing pieces before selecting Op/Event.
... but disable Pass and commit to Event/Op if you do.
Diffstat (limited to 'rules.js')
-rw-r--r--rules.js8
1 files changed, 6 insertions, 2 deletions
diff --git a/rules.js b/rules.js
index 94681b4..58406ef 100644
--- a/rules.js
+++ b/rules.js
@@ -324,7 +324,7 @@ exports.setup = function (seed, scenario, options) {
game.deck.push(i)
}
- log("DEBUG: DECK " + game.deck.join(", "))
+ log("DEBUG DECK " + game.deck.join(", "))
update_control()
@@ -1603,6 +1603,8 @@ states.remove_pieces = {
view.actions.done = 1
},
piece(p) {
+ if (game.op)
+ game.op.pass = 0
remove_piece(p)
},
done() {
@@ -2188,6 +2190,7 @@ function goto_eligible() {
ship: 1,
spaces: [],
pieces: [],
+ pass: 1
}
if (is_final_event_card() || did_option(SOP_1ST_OP_ONLY) || did_option(SOP_1ST_OP_AND_SA)) {
game.op.limited = 1
@@ -2217,7 +2220,8 @@ states.eligible = {
gen_any_operation()
gen_any_event()
}
- view.actions.pass = 1
+ view.actions.remove_pieces = 1
+ view.actions.pass = game.op.pass ? 1 : 0
},
train: goto_train,
patrol: goto_patrol,