'Discord.py Embed
I'm making a discord bot and I made a embed but it's not working I tried to make a new bot with few commands like ping and test but the bot is not replying
async def help(ctx):
if ctx.channel.type != discord.ChannelType.private:
if ctx.channel.id == 973394572627562506:
embed=discord.Embed(title="Help", description=".", color=0x71368A)
embed.set_thumbnail(url=ctx.guild.icon_url)
embed.add_field(name="tt", value="tt", inline=True)
embed.add_field(name="ats", value="fw`", inline=True)
embed.add_field(name="wf", value="awf", inline=True)
embed.add_field(name="he", value="wf", inline=True)
embed.add_field(name="ja", value="ge `(channel)`", inline=True)
embed.add_field(name="Twitch Hosts", value="gw", inline=True)
embed.add_field(name="Twitch Reports", value="!treport `(channel)`", inline=True)
embed.add_field(name="Twitch", value="gww `(channel)`", inline=True)
embed.add_field(name="Twitch ", value="wgw", inline=True)
embed.add_field(name="Twitch ii", value="twtw`", inline=True)
embed.set_footer(text="Made by Flame 'Em -_-rormommemm-_-#4779")
await ctx.send(embed=embed)
else:
await ctx.message.delete()
Solution 1:[1]
Did you add the @bot.command()
decorator to the function? Checkout the docs here. Other than that the code seems right. You can also use the discord embed generator to make sure it will look like what you want and the code matches
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | Lukas Belck |