summaryrefslogtreecommitdiff
path: root/rules.js
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2021-06-23 14:37:40 +0200
committerTor Andersson <tor@ccxvii.net>2022-11-16 19:19:38 +0100
commitba49b45691c35d4b4a1a484f0b8c26e2dcbad206 (patch)
tree6ddf2893ee205e3d4592b2d0ff5c91c10448be88 /rules.js
parentb90969b17567a17d9f2ac44dac7b156daf3d887a (diff)
downloadcrusader-rex-ba49b45691c35d4b4a1a484f0b8c26e2dcbad206.tar.gz
crusader: Add Jihad badges.
Diffstat (limited to 'rules.js')
-rw-r--r--rules.js9
1 files changed, 7 insertions, 2 deletions
diff --git a/rules.js b/rules.js
index c3fe05c..805a581 100644
--- a/rules.js
+++ b/rules.js
@@ -5,7 +5,7 @@
// TODO: can sea move into fortified port that is under attack but not yet besieged?
// TODO: pause after battle ends to show final result/action
-
+// TODO: optional retreat after combat round 3 if storming
exports.scenarios = [
"Third Crusade"
@@ -3357,8 +3357,10 @@ function make_battle_view() {
battle.title += " \u2014 Combat Deployment";
else
battle.title += " \u2014 Round " + game.combat_round;
- if (game.where == game.jihad)
+ if (game.where == game.jihad) {
+ battle.jihad = game.attacker[game.where];
battle.title += " \u2014 Jihad!";
+ }
function fill_cell(cell, owner, fn) {
for (let b in BLOCKS)
@@ -3470,6 +3472,9 @@ exports.view = function(state, current) {
actions: null,
};
+ if (game.jihad && game.jihad != game.p1)
+ view.jihad = game.jihad;
+
states[game.state].prompt(view, current);
if (states[game.state].show_battle)