# Load Roxbots inbuilt cogs and settings | # Load Roxbots inbuilt cogs and settings | ||||
print("Loading Bot internals...") | print("Loading Bot internals...") | ||||
bot.load_extension("roxbot.base") | |||||
print("base.py Loaded") | |||||
bot.load_extension("roxbot.core") | |||||
print("core.py Loaded") | |||||
bot.load_extension("roxbot.err_handle") | bot.load_extension("roxbot.err_handle") | ||||
print("err_handle.py Loaded") | print("err_handle.py Loaded") |
@commands.guild_only() | @commands.guild_only() | ||||
@commands.command() | @commands.command() | ||||
async def pause(self, ctx): | async def pause(self, ctx): | ||||
# TODO: Add some timeouts on pause and resumes | |||||
"""Pauses the current video, if playing.""" | """Pauses the current video, if playing.""" | ||||
if ctx.voice_client.is_paused(): | if ctx.voice_client.is_paused(): | ||||
return await ctx.send("I already am paused!") | return await ctx.send("I already am paused!") |
from discord.ext import commands | from discord.ext import commands | ||||
class Base: | |||||
class Core: | |||||
"""Cog for commands that change the bot account and bot running.""" | """Cog for commands that change the bot account and bot running.""" | ||||
def __init__(self, bot_client): | def __init__(self, bot_client): | ||||
self.bot = bot_client | self.bot = bot_client | ||||
def setup(bot_client): | def setup(bot_client): | ||||
bot_client.add_cog(Base(bot_client)) | |||||
bot_client.add_cog(Core(bot_client)) |