exception added to pdex

This commit is contained in:
phixxy 2024-01-07 13:39:38 -08:00
parent b022a5f60a
commit 26c87482ea

View file

@ -1703,6 +1703,7 @@ async def pokemon(ctx, pokemon):
) )
async def pokedex(ctx, pokemon): async def pokedex(ctx, pokemon):
pokemon = ctx.message.content.split(" ", maxsplit=1)[1] pokemon = ctx.message.content.split(" ", maxsplit=1)[1]
try:
shiny = False shiny = False
if 'shiny ' in pokemon: if 'shiny ' in pokemon:
shiny = True shiny = True
@ -1744,6 +1745,9 @@ async def pokedex(ctx, pokemon):
embed.add_field(name="Height", value=height_str, inline=True) embed.add_field(name="Height", value=height_str, inline=True)
embed.add_field(name="Types", value=type_str, inline=True) embed.add_field(name="Types", value=type_str, inline=True)
await ctx.send(embed=embed) await ctx.send(embed=embed)
except:
message = "No data for " + str(pokemon)
await ctx.channel.send(message)
@bot.command( @bot.command(
description="Kill", description="Kill",