Cooldown timer?

testing
sgoudham 5 years ago
parent d50e0168dd
commit bbe4bd5eac

@ -1,6 +1,8 @@
import discord import discord
import random import random
from discord.ext import commands from discord.ext import commands
from discord.ext.commands import BucketType, cooldown
# Bot Prefix # Bot Prefix
client = commands.Bot(command_prefix='~') client = commands.Bot(command_prefix='~')
@ -82,6 +84,7 @@ async def roles(ctx):
#Bot ~Kakashi command for Zara #Bot ~Kakashi command for Zara
@client.command(aliases=['kakashi']) @client.command(aliases=['kakashi'])
@cooldown(1, 5, BucketType.channel)
async def Kakashi(ctx): async def Kakashi(ctx):
kakashi1 = "https://cdn.discordapp.com/attachments/714671068941647933/717201077346238514/image0.jpg" kakashi1 = "https://cdn.discordapp.com/attachments/714671068941647933/717201077346238514/image0.jpg"
kakashi2 = "https://cdn.discordapp.com/attachments/714671068941647933/717201077669331036/image1.jpg" kakashi2 = "https://cdn.discordapp.com/attachments/714671068941647933/717201077669331036/image1.jpg"

@ -999,6 +999,7 @@ class Bot(BotBase, discord.Client):
""" """
pass pass
class AutoShardedBot(BotBase, discord.AutoShardedClient): class AutoShardedBot(BotBase, discord.AutoShardedClient):
"""This is similar to :class:`.Bot` except that it is inherited from """This is similar to :class:`.Bot` except that it is inherited from
:class:`discord.AutoShardedClient` instead. :class:`discord.AutoShardedClient` instead.

Loading…
Cancel
Save