def guide(self, event, guide_name): if self.config.guides.get(guide_name, "no-guide") == "no-guide": event.msg.reply( ":no_entry_sign: couldn't find that guide. use `+guide list` to find guides." ) return Pages.create_new(self.bot, "guide", event, page=1, guide=guide_name)
def guide(self, event, guide_name): if self.config.guides.get(guide_name, "no-guide") == "no-guide": event.msg.reply( f":no_entry_sign: I couldn't find that guide. Try picking one from the list instead. You can call up this list at any time using `+guide list`." ) self.list_guides(event) return Pages.create_new(self.bot, "guide", event.channel, event.msg, page=1, guide=guide_name)
def guide_send(self, event): randnum = random.random() time.sleep(30) if randnum <= self.experiments["dm-guide-on-join"]: try: channel = event.member.user.open_dm() Pages.create_new(self.bot, "guide", channel, page=1, guide="guide", is_join_dm=True) log_to_bot_log( self.bot, ":green_book: Guide was successfully sent to {user}.". format(user=str(event.member))) except: log_to_bot_log( self.bot, ":no_entry_sign: {user} has DMs disabled, so the guide wasn't sent to them." .format(user=str(event.member)))
def store(self, event): Pages.create_new(self.bot, "xp_store", event.channel, event.msg)
def event_participants(self, event): Pages.create_new(self.bot, "participants", event.channel, event.msg)
def store(self, event): Pages.create_new(self.bot, "xp_store", event)