![](/img/trans.png)
[英]How to use dtype argument in Panda's from_dict (Python)
[英]How to use the from_dict function in Embed messages?
我想发出命令!say [json]
发送嵌入消息。 我在discordpy.readthedocs中找到了from_dict函数。
现在,我不知道如何使用它。 希望对您有所帮助。
对不起,Google翻译:3
谈论这个 ?
因此,这是从字典中嵌入的,下面是一个示例:
@bot.command()
async def embed(ctx, *,title):
e=discord.Embed.from_dict({
"title":f"{title}",
"description":"This is the embed description"
})
await ctx.send(embed=e)
查看该图像中的输出
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.