From ae699ead4dd316d41af45fcfb9af74a0a53e1ab7 Mon Sep 17 00:00:00 2001 From: Cal Corum Date: Mon, 11 Sep 2023 18:01:11 -0500 Subject: [PATCH] Update gameplay.py Add catcher to gamestate embed when there are baserunners --- cogs/gameplay.py | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/cogs/gameplay.py b/cogs/gameplay.py index 2dba184..e3d60a1 100644 --- a/cogs/gameplay.py +++ b/cogs/gameplay.py @@ -396,9 +396,19 @@ class Gameplay(commands.Cog): if game_state['curr_play'].on_third: runner = await get_player(game, game_state['curr_play'].on_third) baserunner_string += f'On Third: {player_link(game, runner)}\n' - embed.add_field( - name='Baserunners', value=baserunner_string if len(baserunner_string) > 0 else 'None', inline=False - ) + + if len(baserunner_string) > 0: + embed.add_field(name=' ', value=' ', inline=False) + embed.add_field( + name='Baserunners', value=baserunner_string + ) + embed.add_field( + name='Catcher', value=f'{player_link(game, game_state["catcher"])}' + ) + else: + embed.add_field( + name='Baserunners', value='None', inline=False + ) # If an AI team is playing if True in [game_state['pitcher']['team']['is_ai'], game_state['batter']['team']['is_ai']]: