Bot pro KSP Discord
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
505 B

import discord
from discord.ext import commands
class Basic(commands.Cog):
def __init__(self, bot):
self.bot = bot
@discord.slash_command(description="Greets the world.")
async def sayhello(self, ctx):
await ctx.respond('Hello world!')
@discord.slash_command(description="Sends the bot's latency.")
async def ping(self, ctx):
await ctx.respond('My ping is {:.0f}ms'.format(self.bot.latency*1000), ephemeral=True)
def setup(bot):
bot.add_cog(Basic(bot))