Exemple #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)
Exemple #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)
Exemple #3
0
def unload(bot: Bot) -> None:
    bot.remove_plugin("Utils")
Exemple #4
0
def load(bot: Bot) -> None:
    bot.add_plugin(Utils(bot))
Exemple #5
0
def unload(bot: Bot) -> None:
    bot.remove_plugin("Events")
Exemple #6
0
def load(bot: Bot) -> None:
    bot.add_plugin(Events(bot))
Exemple #7
0
def unload(bot: Bot) -> None:
    bot.remove_plugin("Help")
Exemple #8
0
def load(bot: Bot) -> None:
    bot.add_plugin(Help(bot))
Exemple #9
0
def unload(bot: Bot) -> None:
    bot.remove_plugin("Admin")
Exemple #10
0
def unload(bot: Bot) -> None:
    bot.remove_plugin("Config")
Exemple #11
0
def load(bot: Bot) -> None:
    bot.add_plugin(Admin(bot))
Exemple #12
0
def load(bot: Bot) -> None:
    bot.add_plugin(Config(bot))
Exemple #13
0
def unload(bot: Bot) -> None:
    bot.remove_plugin("Errors")
Exemple #14
0
def load(bot: Bot) -> None:
    bot.add_plugin(Errors(bot))
Exemple #15
0
def unload(bot: lightbulb.Bot):
    bot.remove_plugin("SuperUser")
Exemple #16
0
def load(bot: lightbulb.Bot):
    bot.add_plugin(SuperUser())