discord.py如何接受用户输入

时间:2020-07-20 19:22:26

标签: python discord

我尝试搜索事物,但没有任何帮助 这些是我的进口货

import discord
import typing
from discord.ext import commands
import random
import time

这是我的代码不起作用

await ctx.send("Enter the number of matches:")
response = await client.wait_for('message', check=lambda m: m.user == ctx.user)
try:
    matches = int(response.content)
except:
    print("That's not a number silly")
await ctx.send("Enter the maximum amount that a player can pick:")
response = await client.wait_for('message', check=lambda m: m.user == ctx.user)
try:
    maxamount = int(response.content)
except:
    print("That's not a number silly")

0 个答案:

没有答案