Skip to content

Commit 331109b

Browse files
authored
fix(werewolves): report game result when game ends at night phase
1 parent dd05db2 commit 331109b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

examples/game/werewolves/game.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,9 @@ async def werewolves_game(agents: list[ReActAgent]) -> None:
261261
# Check winning
262262
res = players.check_winning()
263263
if res:
264-
await moderator(res)
264+
async with MsgHub(players.all_players) as all_players_hub:
265+
res_msg = await moderator(res)
266+
await all_players_hub.broadcast(res_msg)
265267
break
266268

267269
# Discussion

0 commit comments

Comments
 (0)