|
|
|
|
|
|
|
|
await self.bot.change_presence(status=discord_status) |
|
|
await self.bot.change_presence(status=discord_status) |
|
|
await ctx.send("**:ok:** Status set to {}".format(discord_status)) |
|
|
await ctx.send("**:ok:** Status set to {}".format(discord_status)) |
|
|
|
|
|
|
|
|
# TODO: Fix these two commands. |
|
|
|
|
|
|
|
|
|
|
|
@commands.command() |
|
|
|
|
|
@commands.is_owner() |
|
|
|
|
|
async def restart(self, ctx): |
|
|
|
|
|
"""Restarts the bot.""" |
|
|
|
|
|
await self.bot.logout() |
|
|
|
|
|
return os.execl(sys.executable, sys.executable, *sys.argv) |
|
|
|
|
|
|
|
|
|
|
|
@commands.command() |
|
|
@commands.command() |
|
|
@commands.is_owner() |
|
|
@commands.is_owner() |
|
|
async def shutdown(self, ctx): |
|
|
async def shutdown(self, ctx): |
|
|
"""Shuts down the bot.""" |
|
|
"""Shuts down the bot.""" |
|
|
|
|
|
await ctx.send(":wave:") |
|
|
await self.bot.logout() |
|
|
await self.bot.logout() |
|
|
return exit(0) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def setup(bot_client): |
|
|
def setup(bot_client): |