diff options
author | Tor Andersson <tor@ccxvii.net> | 2024-05-24 21:55:23 +0200 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2024-05-30 21:59:25 +0200 |
commit | 6f5be691ae545b8e85ca9549bb8eddb23f567ba2 (patch) | |
tree | 9bcc03cf73785f1b17161acd5728c9936b9cb8b2 /rules.js | |
parent | f8ca38194025196483cbf0a1fcbe43383f1f27dc (diff) | |
download | friedrich-6f5be691ae545b8e85ca9549bb8eddb23f567ba2.tar.gz |
sign
Diffstat (limited to 'rules.js')
-rw-r--r-- | rules.js | 18 |
1 files changed, 11 insertions, 7 deletions
@@ -1945,10 +1945,14 @@ function prompt_combat(value, extra = null) { prompt(format_combat(value) + ".") } -function inactive_combat() { +function inactive_attack() { return "play TC for " + format_combat(game.count) } +function inactive_defend() { + return "play TC for " + format_combat(-game.count) +} + function goto_combat() { set_clear(game.moved) @@ -2083,7 +2087,7 @@ function gen_play_card(suit) { } states.combat_attack = { - inactive: inactive_combat, + inactive: inactive_attack, prompt() { prompt_combat(game.count) view.selected = [ get_supreme_commander(game.attacker) ] @@ -2113,7 +2117,7 @@ states.combat_attack = { } states.combat_defend = { - inactive: inactive_combat, + inactive: inactive_defend, prompt() { prompt_combat(-game.count) @@ -2144,7 +2148,7 @@ states.combat_defend = { } states.combat_attack_reserve = { - inactive: inactive_combat, + inactive: inactive_attack, prompt() { prompt_combat(game.count, "Choose value.") view.selected = [ get_supreme_commander(game.attacker)] @@ -2158,7 +2162,7 @@ states.combat_attack_reserve = { } states.combat_defend_reserve = { - inactive: inactive_combat, + inactive: inactive_defend, prompt() { prompt_combat(-game.count, "Choose value.") view.selected = [ get_supreme_commander(game.defender) ] @@ -2172,7 +2176,7 @@ states.combat_defend_reserve = { } states.combat_attack_swap = { - inactive: inactive_combat, + inactive: inactive_attack, prompt() { prompt_combat(game.count) view.selected = [ get_supreme_commander(game.attacker) ] @@ -2186,7 +2190,7 @@ states.combat_attack_swap = { } states.combat_defend_swap = { - inactive: inactive_combat, + inactive: inactive_defend, prompt() { prompt_combat(-game.count) view.selected = [ get_supreme_commander(game.defender) ] |