示例#1
0
 def menu(initial_control=None):
     if initial_control is None:
         initial_control = NaDiffMenu.id_control
     embed = EmbedMenu(NaDiffMenuPanes.transitions(),
                       initial_control,
                       delete_func=NaDiffMenu.respond_with_delete)
     return embed
示例#2
0
 def menu(initial_control=None):
     if initial_control is None:
         initial_control = NaDiffMenu.id_control
     embed = EmbedMenu(
         NaDiffMenuPanes.transitions(), initial_control,
         EmbedMenuDefaultTransitions(delete_message=EmbedTransition(
             DELETE_MESSAGE_EMOJI, NaDiffMenu.respond_with_delete)))
     return embed
示例#3
0
    def menu(original_author_id, friend_ids, bot_id):
        transitions = {
            LeaderSkillMenu.INITIAL_EMOJI: LeaderSkillMenu.respond_to_house,
            emoji_button_names[1]: LeaderSkillMenu.respond_to_l,
            emoji_button_names[2]: LeaderSkillMenu.respond_to_r,
        }

        valid_emoji_names = [e.name for e in emoji_cache.custom_emojis] + list(transitions.keys())
        reaction_filters = [
            ValidEmojiReactionFilter(valid_emoji_names),
            NotPosterEmojiReactionFilter(),
            BotAuthoredMessageReactionFilter(bot_id),
            MessageOwnerReactionFilter(original_author_id, FriendReactionFilter(original_author_id, friend_ids))
        ]

        return EmbedMenu(reaction_filters, transitions, LeaderSkillMenu.ls_control, menu_emoji_config)
示例#4
0
    def menu(original_author_id, friend_ids, bot_id, initial_control=None):
        if initial_control is None:
            initial_control = IdMenu.id_control

        valid_emoji_names = [e.name for e in emoji_cache.custom_emojis] + list(
            IdMenuPanes.emoji_names())
        reaction_filters = [
            ValidEmojiReactionFilter(valid_emoji_names),
            NotPosterEmojiReactionFilter(),
            BotAuthoredMessageReactionFilter(bot_id),
            MessageOwnerReactionFilter(
                original_author_id,
                FriendReactionFilter(original_author_id, friend_ids))
        ]
        embed = EmbedMenu(reaction_filters, IdMenuPanes.transitions(),
                          initial_control, menu_emoji_config)
        return embed
示例#5
0
    def menu(original_author_id, friend_ids, bot_id):
        transitions = {
            TransformInfoMenu.INITIAL_EMOJI:
            TransformInfoMenu.respond_with_overview,
            emoji_button_names[1]: TransformInfoMenu.respond_with_base,
            emoji_button_names[2]: TransformInfoMenu.respond_with_transform,
        }

        valid_emoji_names = [e.name for e in emoji_cache.custom_emojis] + list(
            transitions.keys())
        reaction_filters = [
            ValidEmojiReactionFilter(valid_emoji_names),
            NotPosterEmojiReactionFilter(),
            BotAuthoredMessageReactionFilter(bot_id),
            MessageOwnerReactionFilter(
                original_author_id,
                FriendReactionFilter(original_author_id, friend_ids))
        ]

        return EmbedMenu(reaction_filters, transitions,
                         TransformInfoMenu.tf_control, menu_emoji_config)
示例#6
0
 def menu():
     return EmbedMenu(LeaderSkillMenuPanes.transitions(),
                      LeaderSkillMenu.ls_control)
示例#7
0
 def menu(initial_control=None):
     if initial_control is None:
         initial_control = MonsterListMenu.monster_list_control
     embed = EmbedMenu(MonsterListMenuPanes.transitions(), initial_control)
     return embed
示例#8
0
 def menu(initial_control=None):
     if initial_control is None:
         initial_control = AwakeningListMenu.awakening_list_control
     embed = EmbedMenu(AwakeningListMenuPanes.transitions(),
                       initial_control)
     return embed
示例#9
0
 def menu():
     embed = EmbedMenu({}, ClosableEmbedMenu.message_control)
     return embed
示例#10
0
 def menu(initial_control=None):
     if initial_control is None:
         initial_control = AzurlaneMenu.pane_control
     embed = EmbedMenu(AzurlaneMenuPanes.transitions(), initial_control)
     return embed
示例#11
0
 def menu(initial_control=None):
     if initial_control is None:
         initial_control = SeriesScrollMenu.monster_list_control
     embed = EmbedMenu(SeriesScrollMenuPanes.transitions(), initial_control)
     return embed
示例#12
0
 def menu():
     embed = EmbedMenu(SimpleMenuPanes.transitions(),
                       SimpleMenu.message_control,
                       delete_func=SimpleMenu.respond_with_delete)
     return embed
示例#13
0
 def menu():
     embed = EmbedMenu(DungeonMenuPanes.transitions(), DungeonMenu.message_control,
                       delete_func=DungeonMenu.respond_with_delete)
     return embed
示例#14
0
 def menu():
     embed = EmbedMenu(
         DungeonMenuPanes.transitions(), DungeonMenu.message_control,
         EmbedMenuDefaultTransitions(delete_message=EmbedTransition(
             DELETE_MESSAGE_EMOJI, DungeonMenu.respond_with_delete)))
     return embed
示例#15
0
 def menu():
     return EmbedMenu(TransformInfoMenuPanes.transitions(), TransformInfoMenu.tf_control)
示例#16
0
 def menu(initial_control=None):
     if initial_control is None:
         initial_control = PADleScrollMenu.control
     embed = EmbedMenu(PADleMenuPanes.transitions(), initial_control)
     return embed
 def menu(cls):
     embed = EmbedMenu({}, cls.message_control)
     return embed
示例#18
0
 def menu():
     return EmbedMenu(ButtonInfoMenuPanes.transitions(),
                      ButtonInfoMenu.button_info_control)
示例#19
0
 def menu(initial_control=None):
     if initial_control is None:
         initial_control = GlobalStatsMenu.control
     embed = EmbedMenu(GlobalStatsMenuPanes.transitions(), initial_control)
     return embed