summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoël Simoneau <simoneaujoel@gmail.com>2025-03-21 08:37:22 -0400
committerJoël Simoneau <simoneaujoel@gmail.com>2025-03-21 08:37:22 -0400
commitbb3fabbf95dd5b6c39672e9f643df32f1f6e923f (patch)
treee378baae75c7cf7fbbb3feec5bec5674be9046d0
parent865d73d80ee00a607a4a6c8aad07d621990febb4 (diff)
downloadvijayanagara-bb3fabbf95dd5b6c39672e9f643df32f1f6e923f.tar.gz
Fix Event 13
-rw-r--r--events.txt10
-rw-r--r--rules.js10
2 files changed, 14 insertions, 6 deletions
diff --git a/events.txt b/events.txt
index 37d2134..ef381d3 100644
--- a/events.txt
+++ b/events.txt
@@ -277,11 +277,15 @@ SHADED 13
endspace
prompt "Select a destination Province for the Rajas."
space 1 (is_adjacent(s, game.vm.m) && has_piece_faction(s, BK))
- prompt "Move any Rajas to the adjacent Province."
- piece all (is_raja(p) && (piece_space(p) === game.vm.m[0]))
+ prompt "Move any number of Rajas to the adjacent Province."
+ piece_opt all (is_raja(p) && (piece_space(p) === game.vm.m[0]))
move
endpiece
- prompt "Make a free Attack against the Vijayanagara Empire there."
+ mark_space
+ endspace
+ current BK
+ prompt "Make a free Attack against the Vijayanagara Empire there."
+ space_opt 1 (game.vm.m[1] === s)
free_attack VE
endspace
diff --git a/rules.js b/rules.js
index 92cd9d8..ea87962 100644
--- a/rules.js
+++ b/rules.js
@@ -1374,7 +1374,7 @@ states.attack_cavalry = {
}
function can_use_cavalry_on_d(d) {
- if (game.dice[d] < 1)
+ if (game.dice[d] <= 1)
return false
if (game.current === game.cmd.target && game.dice[d] === 6 && d < 4)
@@ -6023,11 +6023,15 @@ CODE[13 * 2 + 1] = [
[ vm_endspace ],
[ vm_prompt, "Select a destination Province for the Rajas." ],
[ vm_space, true, 1, 1, (s)=>(is_adjacent(s, game.vm.m) && has_piece_faction(s, BK)) ],
- [ vm_prompt, "Move any Rajas to the adjacent Province." ],
- [ vm_piece, false, 999, 999, (p,s)=>(is_raja(p) && (piece_space(p) === game.vm.m[0])) ],
+ [ vm_prompt, "Move any number of Rajas to the adjacent Province." ],
+ [ vm_piece, false, 0, 999, (p,s)=>(is_raja(p) && (piece_space(p) === game.vm.m[0])) ],
[ vm_move ],
[ vm_endpiece ],
+ [ vm_mark_space ],
+ [ vm_endspace ],
+ [ vm_current, BK ],
[ vm_prompt, "Make a free Attack against the Vijayanagara Empire there." ],
+ [ vm_space, true, 0, 1, (s)=>(game.vm.m[1] === s) ],
[ vm_free_attack, VE ],
[ vm_endspace ],
[ vm_return ],