Skip to content

Commit

Permalink
Merge pull request #3353 from rustykitty/issue-3348
Browse files Browse the repository at this point in the history
fixed medicine den text adjusting error
  • Loading branch information
j-gynn authored Jan 11, 2025
2 parents fdab408 + 4fd3787 commit 9c5df2a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
5 changes: 3 additions & 2 deletions scripts/conditions.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,10 @@ def medical_cats_condition_fulfilled(all_cats,
can_care_for = int(adjust_med_number * (amount_per_med + 1))

relevant_cats = list(
filter(lambda c: not c.dead and not c.outside, all_cats))
filter(lambda c: not c.dead and not c.outside, all_cats)
)

if give_clanmembers_covered is True:
if give_clanmembers_covered:
return can_care_for
if can_care_for >= len(relevant_cats):
fulfilled = True
Expand Down
12 changes: 7 additions & 5 deletions scripts/screens/MedDenScreen.py
Original file line number Diff line number Diff line change
Expand Up @@ -356,6 +356,7 @@ def screen_switches(self):
clansize=number,
count=len(self.meds)
)

if game.clan.game_mode == "classic":
meds_cover = ""

Expand All @@ -375,11 +376,12 @@ def screen_switches(self):
clan=game.clan
)

med_messages.append(event_text_adjust(
Cat,
meds_cover,
main_cat=self.meds[0]
))
if meds_cover:
med_messages.append(event_text_adjust(
Cat,
meds_cover,
main_cat=self.meds[0]
))

if self.meds:
med_messages.append(game.clan.herb_supply.get_status_message(choice(self.meds)))
Expand Down

0 comments on commit 9c5df2a

Please sign in to comment.