diff --git a/cogs/gameplay.py b/cogs/gameplay.py index c635ee5..779fc27 100644 --- a/cogs/gameplay.py +++ b/cogs/gameplay.py @@ -76,6 +76,8 @@ class Gameplay(commands.Cog): gt_string = 'Gauntlet' elif x.game_type == 'flashback': gt_string = 'Flashback' + elif 'exhibition' in x.game_type: + gt_string = 'Exhibition' embed.add_field( name=f'{gs["away_team"]["sname"]} @ {gs["home_team"]["sname"]} - {gt_string}', value=g_message, @@ -1839,7 +1841,7 @@ class Gameplay(commands.Cog): async def get_ai_sp_roster(interaction, this_game, ai_team, home_team, league_name, all_lineups): # Get AI Starting Pitcher try: - await interaction.edit_original_response( + await interaction.channel.send( content=f'Now to decide on a Starting Pitcher...' ) if ai_team['id'] == this_game.away_team_id: @@ -1865,7 +1867,7 @@ class Gameplay(commands.Cog): except Exception as e: patch_game(this_game.id, active=False) logging.error(f'could not start an AI game with {ai_team["sname"]}: {e}') - await interaction.edit_original_response( + await interaction.channel.send( content=f'Looks like the {ai_team["sname"]} rotation didn\'t come through clearly. I\'ll sort ' f'this out with {ai_team["gmname"]} and {get_cal_user(interaction).mention}. I\'ll end ' f'this game - why don\'t you play against somebody else for now?' @@ -1874,7 +1876,7 @@ class Gameplay(commands.Cog): # Get AI Lineup try: - await interaction.edit_original_response( + await interaction.channel.send( content=f'I am getting a lineup card from the {ai_team["sname"]}...' ) diff --git a/in_game/ai_manager.py b/in_game/ai_manager.py index bafa2a7..928b8be 100644 --- a/in_game/ai_manager.py +++ b/in_game/ai_manager.py @@ -106,8 +106,9 @@ def batter_grading(vs_hand, rg_data): def get_cardset_string(this_game: StratGame): cardsets = '' bcardsets = '' - for x in this_game.cardset_ids.split(','): - cardsets += f'&cardset_id={x}' + if this_game.cardset_ids is not None: + for x in this_game.cardset_ids.split(','): + cardsets += f'&cardset_id={x}' if this_game.backup_cardset_ids is not None: for x in this_game.backup_cardset_ids.split(','): bcardsets += f'&backup_cardset_id={x}'