Skip to content

Commit

Permalink
fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
flick-ai committed Jun 5, 2024
1 parent 3f34a6c commit fa8cf9d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
5 changes: 3 additions & 2 deletions genius_invocation/card/action/event/events/WaterandJustice.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ class WaterandJustice(ActionCard):
name_ch = "水与正义"
cost_num = 2
cost_type = CostType.BLACK
country = CountryType.FONTAINE
card_type = ActionCardType.EVENT_COUNTRY

def __init__(self) -> None:
Expand All @@ -20,7 +21,7 @@ def calculate_target_point(self,sum_point: int, max_points: List[int]):
need_character = len(max_points)
target_point = [0 for i in range(need_character)]
target_idx = [i for i in range(need_character)]

while sum_point > 0:
for idx in target_idx:
target_point[idx] += 1
Expand All @@ -29,7 +30,7 @@ def calculate_target_point(self,sum_point: int, max_points: List[int]):
break
if max_points[idx] == target_point[idx]:
target_idx.remove(idx)

return target_point


Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
from genius_invocation.card.character.import_head import *
from genius_invocation.card.action.base import ActionCard

class ScorpionStrike(NormalAttack):
id: int = 24051
Expand Down
2 changes: 1 addition & 1 deletion genius_invocation/card/character/characters/Xinyan.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,5 +146,5 @@ def damage_add(self, game: 'GeniusGame'):
game.current_damage.main_damage += 2
self.use_talent_round = game.round

def listen_talent_events(self, game: GeniusGame):
def listen_talent_events(self, game: 'GeniusGame'):
self.listen_event(game, EventType.DAMAGE_ADD, ZoneType.CHARACTER_ZONE, self.damage_add)

0 comments on commit fa8cf9d

Please sign in to comment.