QOL Updates

This commit is contained in:
Marco Thomas
2021-03-03 17:44:47 +01:00
parent e14a1ef2a3
commit 87bce0be57
12 changed files with 24 additions and 104 deletions

View File

@@ -1,11 +1,10 @@
"""
Admin commands, that can be used from within the discord-client-chat
Admin commands, that can be used within the Discord Client
"""
import discord
from discord.ext import commands
class Admin(commands.Cog):
def __init__(self, bot):
self.bot = bot

View File

@@ -1,5 +1,5 @@
"""
Some help for the users
User help
"""
import discord
@@ -7,7 +7,6 @@ from discord.ext import commands
from __main__ import PREFIX
class Help(commands.Cog):
def __init__(self, bot):
self.bot = bot

View File

@@ -1,5 +1,5 @@
"""
Jikan is an unofficial api to access data from myanimelist
Jikan is an unofficial API to access data from MyAnimeList
https://jikanpy.readthedocs.io/en/latest/
"""
@@ -7,13 +7,13 @@ import discord
from discord.ext import commands
from jikanpy import Jikan
jikan = Jikan()
class Jikan(commands.Cog):
def __init__(self, bot):
self.bot = bot
@commands.group(name="anime")
async def anime(self, ctx):
if ctx.invoked_subcommand is None:

View File

@@ -8,7 +8,6 @@ import random
import memes
class Meme(commands.Cog):
def __init__(self, bot):
self.bot = bot

View File

@@ -1,7 +1,7 @@
"""
Play Music
A COG ORIGINALLY CREATED BY ME, I ALTERED THIS ONE TO FIT MY NEEDS
A COG ORIGINALLY NOT CREATED BY ME, I ALTERED THIS ONE TO FIT MY NEEDS
https://gist.github.com/vbe0201/ade9b80f2d3b64643d854938d40a0a2d
"""
@@ -392,18 +392,6 @@ class Music(commands.Cog):
if ctx.voice_client.channel != ctx.author.voice.channel:
raise commands.CommandError('Bot is already in a voice channel.')
# @commands.command(name='loop')
# async def loop(self, ctx: commands.Context):
# """
# Loops the currently playing song.
# """
# if not ctx.voice_state.is_playing:
# return await ctx.send('Nothing being played at the moment.')
#
# # Swap states
# ctx.voice_state.loop = not ctx.voice_state.loop
# await ctx.message.add_reaction('✅')
@commands.command(name="queue")
async def queue(self, ctx: commands.Context):

View File

@@ -11,7 +11,6 @@ from __main__ import REDDIT_CLIENT_ID
from __main__ import REDDIT_CLIENT_SECRET
from __main__ import REDDIT_CLIENT_USERAGENT
class Reddit(commands.Cog):
def __init__(self, bot):
self.bot = bot

View File

@@ -1,17 +0,0 @@
"""
A simple reminder option
"""
import discord
from discord.ext import commands
class Reminder(commands.Cog):
def __init__(self, bot):
self.bot = bot
def setup(bot):
bot.add_cog(Reminder(bot))

View File

@@ -1,5 +1,5 @@
"""
Some (more or less) handy utility
Some utility commands
"""
import discord

View File

@@ -1,33 +0,0 @@
"""
Welcoming new users etc.
"""
import discord
from discord.ext import commands
class Welcome(commands.Cog):
def __init__(self, bot):
self.bot = bot
@commands.Cog.listener()
async def on_member_join(self, member):
"""
Greets new users joining your server
"""
channel = member.guild.system_channel
text = f"Welcome {member.mention} to our Discord!"
if channel is not None:
await channel.send(text)
@commands.command(name="hello")
async def hello(self, ctx):
"""
Sends a simple reply to the user
"""
await ctx.send(f"Hello {ctx.author.mention}!")
def setup(bot):
bot.add_cog(Welcome(bot))