Example #1
0
 def __init__(self, bot: Bot) -> None:
     super().__init__()
     self.bot = bot
     self.old_help_command = bot.help_command
     bot.help_command = CustomHelp(bot)
     bot.remove_command("help")
     bot.add_command(_help_cmd)
Example #2
0
    def __init__(self, bot: Bot):
        super().__init__()
        self.bot = bot

        if GUILD_LOGS_WEBHOOK_URL:
            webhook_id, webhook_token = GUILD_LOGS_WEBHOOK_URL.strip(
                "/").split("/")[-2:]
            self.execute_webhook = partial(self.bot.rest.execute_webhook,
                                           int(webhook_id), webhook_token)

            for event_type, callback in self.optional_events:
                bot.subscribe(event_type, callback)
Example #3
0
def unload(bot: Bot) -> None:
    bot.remove_plugin("Utils")
Example #4
0
def load(bot: Bot) -> None:
    bot.add_plugin(Utils(bot))
Example #5
0
def unload(bot: Bot) -> None:
    bot.remove_plugin("Events")
Example #6
0
def load(bot: Bot) -> None:
    bot.add_plugin(Events(bot))
Example #7
0
def unload(bot: Bot) -> None:
    bot.remove_plugin("Help")
Example #8
0
def load(bot: Bot) -> None:
    bot.add_plugin(Help(bot))
Example #9
0
def unload(bot: Bot) -> None:
    bot.remove_plugin("Admin")
Example #10
0
def unload(bot: Bot) -> None:
    bot.remove_plugin("Config")
Example #11
0
def load(bot: Bot) -> None:
    bot.add_plugin(Admin(bot))
Example #12
0
def load(bot: Bot) -> None:
    bot.add_plugin(Config(bot))
Example #13
0
def unload(bot: Bot) -> None:
    bot.remove_plugin("Errors")
Example #14
0
def load(bot: Bot) -> None:
    bot.add_plugin(Errors(bot))
Example #15
0
def unload(bot: lightbulb.Bot):
    bot.remove_plugin("SuperUser")
Example #16
0
def load(bot: lightbulb.Bot):
    bot.add_plugin(SuperUser())