bot.py 文件源码

python
阅读 29 收藏 0 点赞 0 评论 0

项目:ModTools 作者: MattBSG 项目源码 文件源码
def cmd_shutdown(self, channel, author, server):
        """
        Usage: {command_prefix}forcebackup
        Forces a back up of all server configs
        """
        if author.id in [self.config.master_id]:
            await self.safe_send_message(discord.Object(id='155553608400764928'),
                                         '__**<@{}>**__ shutdown made in *{}* on `{}`'.format(author.id,
                                                                                           channel.name,
                                                                                           server.name
                                                                                           )
                                         )
            await self.safe_send_message(channel, '**Powering off :see_no_evil:**')
            await self.backup_config(self.server_index)
            await self.logout()
        return
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号