我正在开发一个机器人来促进我们团队手头的一些事情。我开始创建一些运行良好的任务,我需要创建一个从周一到周五 16 点运行的通知,我看到了一些博客,我尝试申请但没有成功,今天这是我的代码和功能我想调用称为“LEMBRAR()”,我想知道我必须运行它的选项。
import discord
from discord.ext import commands, tasks
from discord.ext.commands import has_permissions
from BotGooBee.Humor import GooBee
hora = '16:00'
diasSemanas = 'seg-sex'
client = commands.Bot(command_prefix='?')
@client.event
async def on_ready():
print('bot online')
@client.command()
async def limpar(ctx, amount=100):
await ctx.channel.purge(limit=amount)
@client.command()
async def ping(ctx):
await ctx.send(f'Pong! {round(client.latency * 1000)}ms')
@client.command()
async def feliz(ctx):
GooBee(1).AtualizarHumor()
await ctx.send('Humor alterado | FELIZ')
@client.command()
async def normal(ctx):
GooBee(2).AtualizarHumor()
await ctx.send('Humor alterado | NORMAL')
@client.command()
async def irritado(ctx):
GooBee(3).AtualizarHumor()
await ctx.send('Humor alterado | IRRITADO')
async def lembrar():
print('hello')
channel = client.get_channel(id_channel)
await channel.send('hello')
client.run(token)
潇湘沐
隔江千里
相关分类