diff options
author | Tor Andersson <tor@ccxvii.net> | 2024-04-29 23:02:47 +0200 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2024-04-29 23:02:47 +0200 |
commit | 29a76580ca56f5fe1e45107800c7679abb377a16 (patch) | |
tree | f06220af98534cd5b83f4f71ebeb892e4adbe424 | |
parent | 71c545d061f4d73188acf4ac4584c762b390b878 (diff) | |
download | plantagenet-29a76580ca56f5fe1e45107800c7679abb377a16.tar.gz |
fix dorset cost
-rw-r--r-- | rules.ts | 26 |
1 files changed, 12 insertions, 14 deletions
@@ -1962,9 +1962,7 @@ function parley_ic_cost(lord: Lord, spend: number) { } if (is_levy_phase()) { - if (lord === LORD_DEVON && get_lord_locale(LORD_DEVON) === LOC_EXETER && is_event_in_play(EVENT_YORK_DORSET)) - cost = 0 - else if (game.levy_flags.jack_cade > 0) { + if (game.levy_flags.jack_cade > 0) { cost = 0 } else { if (game.levy_flags.parliament_votes > 0) @@ -1972,6 +1970,9 @@ function parley_ic_cost(lord: Lord, spend: number) { if (game.levy_flags.succession > 0) cost -= 1 } + } else { + if (lord === LORD_DEVON && get_lord_locale(lord) === LOC_EXETER && is_event_in_play(EVENT_YORK_DORSET)) + cost = 0 } return cost @@ -1991,22 +1992,19 @@ function vassal_ic_success(lord: Lord) { return false } -function parley_ic_success() { - if (game.active === LANCASTER) { - if (is_levy_phase()) { +function parley_ic_success(lord: Lord) { + if (is_levy_phase()) { + if (game.levy_flags.jack_cade > 0) { + return true + } else { if (game.levy_flags.parliament_votes > 0) return true - } - } else { - if (is_levy_phase()) { if (game.levy_flags.succession > 0) return true - if (game.levy_flags.jack_cade > 0) - return true - } else { - if (game.command === LORD_DEVON && get_lord_locale(LORD_DEVON) === LOC_EXETER && is_event_in_play(EVENT_YORK_DORSET)) - return true } + } else { + if (lord === LORD_DEVON && get_lord_locale(lord) === LOC_EXETER && is_event_in_play(EVENT_YORK_DORSET)) + return true } return false } |