diff options
author | teisuru <31881306+teisuru@users.noreply.github.com> | 2023-09-04 13:01:44 +0200 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2023-12-10 18:16:55 +0100 |
commit | a88f4cd6fd7e7014a50e8d862c6c55f54a2a85e7 (patch) | |
tree | 5a86960d6385bd12fea182edbdc4f314f83a31da | |
parent | 338ec04282c5a125448fdb9db39fdb437ab6a216 (diff) | |
download | plantagenet-a88f4cd6fd7e7014a50e8d862c6c55f54a2a85e7.tar.gz |
forage adjacent die roll
-rw-r--r-- | rules.js | 11 |
1 files changed, 11 insertions, 0 deletions
@@ -3503,6 +3503,17 @@ function can_action_forage() { function goto_forage() { push_undo() let here = get_lord_locale(game.command) + for (let next of data.locales[here].adjacent) + if (has_enemy_lord(next)) { + let die = roll_die() + if (die <= 4) { + add_lord_assets(game.command, PROV, 1) + log(`${HIT[die]}, Successful Forage`) + } + else { + log(`${MISS[die]}, Forage Failure`) + } + } log(`Foraged at %${here}`) add_lord_assets(game.command, PROV, 1) deplete_locale(here) |