diff options
-rw-r--r-- | events.txt | 14 | ||||
-rw-r--r-- | rules.js | 12 |
2 files changed, 12 insertions, 14 deletions
@@ -282,9 +282,10 @@ CARD 42 - Paris Cannons CARD 43 - Aux Barricades! ops 2 PARIS - player COMMUNE - prompt "You may place a Barricade in Butte-aux-Cailles." - may_place_disc BUTTE_AUX_CAILLES + if (game.active === COMMUNE) + prompt "You may place a Barricade in Butte-aux-Cailles." + may_place_disc BUTTE_AUX_CAILLES + endif CARD 44 - Commune's Stronghold prompt "Use 2 OP in Military or remove 1 from any space." @@ -298,9 +299,10 @@ CARD 44 - Commune's Stronghold CARD 45 - Fighting in Issy Village ops 2 FORTS - player VERSAILLES - prompt "You may place a Fortification in Fort d'Issy." - may_place_disc FORT_D_ISSY + if (game.active === VERSAILLES) + prompt "You may place a Fortification in Fort d'Issy." + may_place_disc FORT_D_ISSY + endif CARD 46 - Battle of Mont-Valérien ops 3 FORTS @@ -2644,12 +2644,6 @@ function vm_case() { } } -function vm_player() { - // TODO: pause for undo? - game.active = vm_operand(1) - vm_next() -} - function vm_ops() { goto_operations(vm_operand(1), vm_operand_spaces(2)) } @@ -4031,9 +4025,10 @@ CODE[42] = [ // Paris Cannons CODE[43] = [ // Aux Barricades! [ vm_ops, 2, PARIS ], - [ vm_player, COMMUNE ], + [ vm_if, ()=>(game.active === COMMUNE) ], [ vm_prompt, "You may place a Barricade in Butte-aux-Cailles." ], [ vm_may_place_disc, BUTTE_AUX_CAILLES ], + [ vm_endif ], [ vm_return ], ] @@ -4051,9 +4046,10 @@ CODE[44] = [ // Commune's Stronghold CODE[45] = [ // Fighting in Issy Village [ vm_ops, 2, FORTS ], - [ vm_player, VERSAILLES ], + [ vm_if, ()=>(game.active === VERSAILLES) ], [ vm_prompt, "You may place a Fortification in Fort d'Issy." ], [ vm_may_place_disc, FORT_D_ISSY ], + [ vm_endif ], [ vm_return ], ] |