将值插入函数

问题描述 投票:0回答:1

我是python的新手(从今天开始,2020年5月28日开始使用python,我以前使用过Lua并非常了解它。我试图做一些基本的事情,但我根本不知道该怎么做。我想利用用户价值,并希望它代替作者,而是向我选择的用户发送消息。 (在DM中)我将如何做?

@bot.command()
async def remind(ctx,user):
    await ctx.author.send("Hello") ##Want to replace author with a username/ID.

在RBX lua中,如果我没记错的话,您只需要执行“ ctx [user] .send”我在这里怎么办?

python discord discord.py
1个回答
0
投票

看看这个链接https://discordpy.readthedocs.io/en/latest/api.html#,它有一些不错的东西,将回答您的问题

© www.soinside.com 2019 - 2024. All rights reserved.