From c50216132981a993fb827315c7c4d6fb3d5857a1 Mon Sep 17 00:00:00 2001 From: Matt Kohls Date: Sun, 27 Oct 2019 00:38:52 -0400 Subject: Starting work to update libraries JDA v4 has many breaking changes that will need to be checked Lavaplayer shouldn't have any major changes, but needs version bump to continue working with various sites --- src/main/java/soundchan/Main.java | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'src/main/java/soundchan/Main.java') diff --git a/src/main/java/soundchan/Main.java b/src/main/java/soundchan/Main.java index a7aa6a3..587c7e9 100644 --- a/src/main/java/soundchan/Main.java +++ b/src/main/java/soundchan/Main.java @@ -1,8 +1,8 @@ package soundchan; -import net.dv8tion.jda.core.AccountType; -import net.dv8tion.jda.core.JDA; -import net.dv8tion.jda.core.JDABuilder; +import net.dv8tion.jda.api.AccountType; +import net.dv8tion.jda.api.JDA; +import net.dv8tion.jda.api.JDABuilder; import soundchan.BotListener.*; import java.io.FileInputStream; @@ -17,10 +17,9 @@ public class Main { JDA jda = new JDABuilder(AccountType.BOT) .setToken(properties.getProperty("botToken")) - .buildBlocking(); - - - jda.addEventListener(new BotListener(properties)); + .addEventListeners(new BotListener(properties)) + .build(); + jda.awaitReady(); } private static Properties LoadProperties(){ -- cgit v1.2.3