Group rest: everyone heals at their own pace
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
67a1ab876a
commit
1bf3f3b62f
3 changed files with 20 additions and 5 deletions
|
|
@ -966,6 +966,19 @@ class DungeonTest(unittest.TestCase):
|
|||
self.assertLessEqual(fight["rest"], 3)
|
||||
self.assertLess(game.member_of(fight, "kay")["hp_in"], game.max_hp(self.kay) / 2)
|
||||
|
||||
def test_a_pull_early_heals_each_at_their_own_pace(self):
|
||||
game.start_action(self.world, self.wil, "dungeon_watchtower", T0)
|
||||
game.join_fight(self.world, self.kay, "wil", T0)
|
||||
game.start_run(self.world, self.wil, T0)
|
||||
self.wil["hp"], self.kay["hp"] = game.max_hp(self.wil) - 5, 1
|
||||
self.online(T0 + 0.5)
|
||||
fight = self.party()["fight"]
|
||||
wil = game.member_of(fight, "wil")
|
||||
self.assertLess(wil["rest"], fight["rest"]) # done resting first, waiting on Kay
|
||||
self.assertIsNone(game.pull_now(self.world, self.wil, T0 + wil["rest"] / fight["pace"] + 1))
|
||||
self.assertEqual(wil["hp_in"], game.max_hp(self.wil))
|
||||
self.assertLess(game.member_of(fight, "kay")["hp_in"], game.max_hp(self.kay))
|
||||
|
||||
def test_adds_join_halfway_and_never_count_if_they_dont(self):
|
||||
foes = game.DUNGEONS["dungeon_watchtower"]["pulls"][7][1]
|
||||
self.assertTrue(foes[1]["dormant"] and foes[2]["dormant"])
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue