From 1336a3ed4ff1494d696bf9ffa32fc41641824f27 Mon Sep 17 00:00:00 2001 From: Ev-1 <33662061+Ev-1@users.noreply.github.com> Date: Thu, 27 Aug 2020 12:48:01 +0200 Subject: [PATCH] Added working help invoker, changed config structure --- cogs/nodemanager.py | 8 +++++--- data/config.yaml.example | 17 +++++++---------- 2 files changed, 12 insertions(+), 13 deletions(-) diff --git a/cogs/nodemanager.py b/cogs/nodemanager.py index c6e2603..7dc8767 100644 --- a/cogs/nodemanager.py +++ b/cogs/nodemanager.py @@ -9,7 +9,8 @@ import codecs import yaml from .utils.mixplayer import MixPlayer - +from cogs.helpformatter import commandhelper +from cogs.utils.paginator import Scroller class NodeManager(commands.Cog): def __init__(self, bot): @@ -100,9 +101,10 @@ class NodeManager(commands.Cog): @commands.group(name='node', hidden=True) @commands.is_owner() async def _node(self, ctx): - # TODO: @Even help if ctx.invoked_subcommand is None: - await ctx.invoke(self.bot.get_command('help'), ctx.command.qualified_name) + paginator = commandhelper(ctx, ctx.command, ctx.invoker, include_subcmd=True) + scroller = Scroller(ctx, paginator) + await scroller.start_scrolling() @_node.command(name='reload_file') @commands.is_owner() diff --git a/data/config.yaml.example b/data/config.yaml.example index f1f4f8b..281354f 100644 --- a/data/config.yaml.example +++ b/data/config.yaml.example @@ -19,20 +19,17 @@ default server settings: dynamic max duration: Yes lavalink nodes: - main: # The preferred lavalink node for your music bot - host: localhost + - host: localhost port: 2333 password: youshallnotpass region: eu - name: default-node + name: main - # Backup nodes for your music bot - backup: - - host: localhost - port: 2333 - password: youshallnotpass - region: eu - name: backup-1 + - host: localhost + port: 2333 + password: youshallnotpass + region: eu + name: backup-1 APIkeys: genius: