async def art(self, client: Client, channel: Channel, args: str, author: Member, **_: Dict[str, Any]) -> None: """`!art {name}` Display the art (only) of the most recent printing of the named card.""" await client.send_typing(channel) c = await single_card_or_send_error(client, channel, args, author, 'art') if c is not None: file_path = image_fetcher.determine_filepath([c]) + '.art_crop.jpg' if image_fetcher.download_scryfall_image([c], file_path, version='art_crop'): await send_image_with_retry(client, channel, file_path) else: await client.send_message(channel, '{author}: Could not get image.'.format(author=author.mention))
async def art(self, bot, channel, args, author): """`!art {name}` Display the art (only) of the most recent printing of the named card.""" await bot.client.send_typing(channel) c = await single_card_or_send_error(bot, channel, args, author, "art") if c is not None: image_file = image_fetcher.download_scryfall_image( [c], image_fetcher.determine_filepath([c]) + '.art_crop.jpg', version='art_crop') await bot.send_image_with_retry(channel, image_file)
async def art(ctx: MtgContext, *, c: Card) -> None: """Display the artwork of the requested card.""" if c is not None: file_path = re.sub('.jpg$', '.art_crop.jpg', image_fetcher.determine_filepath([c])) success = await image_fetcher.download_scryfall_card_image( c, file_path, version='art_crop') if success: await ctx.send_image_with_retry(file_path) else: await ctx.send('{author}: Could not get image.'.format( author=ctx.author.mention))
async def art(self, channel: TextChannel, args: str, author: Member, **_: Dict[str, Any]) -> None: """`!art {name}` Display the art (only) of the most recent printing of the named card.""" if not args: return await channel.send( '{author}: Please specify a card name.'.format( author=author.mention)) c = await single_card_or_send_error(channel, args, author, 'art') if c is not None: file_path = re.sub('.jpg$', '.art_crop.jpg', image_fetcher.determine_filepath([c])) if image_fetcher.download_scryfall_card_image(c, file_path, version='art_crop'): await send_image_with_retry(channel, file_path) else: await channel.send('{author}: Could not get image.'.format( author=author.mention))