質問編集履歴

1

該当のコードを変更しました

2022/09/29 22:30

投稿

BLUE43
BLUE43

スコア2

test CHANGED
File without changes
test CHANGED
@@ -19,10 +19,30 @@
19
19
  Python (Discord.py)
20
20
 
21
21
  該当のソースコード
22
+ ```python
23
+ import discord
24
+ from discord.ext import commands
25
+ import random
26
+ from discord import Permissions
27
+ from colorama import Fore, Style
28
+ import asyncio
29
+
30
+ from flask import Flask
31
+ from threading import Thread
32
+
33
+ token = "token"
34
+
35
+ client = commands.Bot(command_prefix="!")
36
+
37
+ @client.command()
22
38
  async def membercount(ctx):
23
39
  await ctx.send(ctx.guild.member_count)
24
- if ctx.guild.member_count is 3:
40
+ if (ctx.guild.member_count == 3:)
25
- await guild.leave()
41
+ await guild.leave() # Guild found
42
+
43
+ client.run(token, bot=True)
44
+
45
+ ```
26
46
 
27
47
 
28
48