From b4a2b958b117b78f765d707327839281020b687f Mon Sep 17 00:00:00 2001 From: Kosugi_kun <33971692+kosugikun@users.noreply.github.com> Date: Fri, 17 Dec 2021 20:06:56 +0900 Subject: [PATCH] =?UTF-8?q?=E4=B8=8D=E5=85=B7=E5=90=88=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/com/jagrosh/jmusicbot/BotConfig.java | 8 ++++---- src/main/java/com/jagrosh/jmusicbot/JMusicBot.java | 3 ++- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/main/java/com/jagrosh/jmusicbot/BotConfig.java b/src/main/java/com/jagrosh/jmusicbot/BotConfig.java index 35e2933d9..e51efdf3a 100644 --- a/src/main/java/com/jagrosh/jmusicbot/BotConfig.java +++ b/src/main/java/com/jagrosh/jmusicbot/BotConfig.java @@ -70,9 +70,9 @@ public BotConfig(Prompt prompt) { public void load() { valid = false; - // read config from file + // ファイルからの設定の読み込み try { - // get the path to the config, default config.txt + // 設定のパスを取得(デフォルトはconfig.txt) path = OtherUtil.getPath(System.getProperty("config.file", System.getProperty("config", "config.txt"))); if(path.toFile().exists()) { @@ -81,11 +81,11 @@ public void load() { ConfigFactory.invalidateCaches(); } - // load in the config file, plus the default values + // 設定ファイルにロードされ、デフォルト値が追加される //Config config = ConfigFactory.parseFile(path.toFile()).withFallback(ConfigFactory.load()); Config config = ConfigFactory.load(); - // set values + // 設定値 token = config.getString("token"); prefix = config.getString("prefix"); altprefix = config.getString("altprefix"); diff --git a/src/main/java/com/jagrosh/jmusicbot/JMusicBot.java b/src/main/java/com/jagrosh/jmusicbot/JMusicBot.java index d4431d0d9..179ff14dc 100644 --- a/src/main/java/com/jagrosh/jmusicbot/JMusicBot.java +++ b/src/main/java/com/jagrosh/jmusicbot/JMusicBot.java @@ -182,6 +182,7 @@ public static void main(String[] args) { // Admin add(new PrefixCmd(bot)); add(new SetdjCmd(bot)); + add(new SkipratioCmd(bot)); add(new SettcCmd(bot)); add(new SetvcCmd(bot)); add(new AutoplaylistCmd(bot)); @@ -194,7 +195,7 @@ public static void main(String[] args) { add(new SetstatusCmd(bot)); add(new PublistCmd(bot)); add(new ShutdownCmd(bot)); - add(new LeaveCmd(bot)); + //add(new LeaveCmd(bot)); }}; cb.addCommands(commandList.toArray(new Command[0]));