Skip to content

Commit a3fda69

Browse files
committed
fix: tourist inference
1 parent d2d59e5 commit a3fda69

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

hearthstone/entities.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ def register_entity(self, entity: Entity) -> None:
140140
# Infer Tourists when they reveal themselves
141141
if (
142142
entity.tags.get(GameTag.ZONE) == Zone.REMOVEDFROMGAME and
143-
entity.tags.get(GameTag.TOURIST) == 1
143+
entity.tags.get(GameTag.TOURIST, 0) > 0
144144
):
145145
# This might be the fake Tourist that the game pops up to explain why a card was
146146
# present in the player's deck. Double-check that the card was created by the

tests/test_entities.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -337,7 +337,7 @@ def test_known_starting_deck_list_with_tourist(self, game, player):
337337
GameTag.CONTROLLER: player.player_id,
338338
GameTag.CREATOR: vfx.id,
339339
GameTag.ZONE: Zone.REMOVEDFROMGAME,
340-
GameTag.TOURIST: 1,
340+
GameTag.TOURIST: 2,
341341
GameTag.DRUID_TOURIST: 1,
342342
})
343343
game.register_entity(fake_tourist)

0 commit comments

Comments
 (0)