File tree Expand file tree Collapse file tree 3 files changed +10
-7
lines changed
src/main/java/org/mangorage/mangobotplugin Expand file tree Collapse file tree 3 files changed +10
-7
lines changed Original file line number Diff line number Diff line change @@ -77,7 +77,7 @@ dependencies {
7777 library(' org.slf4j:slf4j-simple:2.0.13' ) // Use a recent version)
7878 library(' org.luaj:luaj-jme:3.0.1' )
7979
80- library(' dev.arbjerg:lavaplayer:2.2.3 ' )
80+ library(' dev.arbjerg:lavaplayer:2.2.1 ' )
8181 library(' dev.lavalink.youtube:common:+' )
8282}
8383
Original file line number Diff line number Diff line change 2222
2323package org .mangorage .mangobotplugin .commands .music ;
2424
25+ import com .sedmelluq .discord .lavaplayer .format .StandardAudioDataFormats ;
2526import com .sedmelluq .discord .lavaplayer .player .AudioConfiguration ;
2627import com .sedmelluq .discord .lavaplayer .player .AudioLoadResultHandler ;
2728import com .sedmelluq .discord .lavaplayer .player .AudioPlayer ;
@@ -71,6 +72,8 @@ private MusicPlayer(String guildID) {
7172
7273 manager .enableGcMonitoring ();
7374 manager .getConfiguration ().setResamplingQuality (AudioConfiguration .ResamplingQuality .HIGH );
75+ manager .getConfiguration ().setOutputFormat (StandardAudioDataFormats .COMMON_PCM_S16_BE );
76+
7477
7578 MusicUtil .registerRemoteSources (manager );
7679
@@ -201,6 +204,6 @@ public ByteBuffer provide20MsAudio() {
201204
202205 @ Override
203206 public boolean isOpus () {
204- return true ;
207+ return false ;
205208 }
206209}
Original file line number Diff line number Diff line change @@ -8,10 +8,10 @@ public final class ModuleConfigurator implements IModuleConfigurator {
88
99 @ Override
1010 public List <String > getChildren (String s ) {
11- System . out . println ( "Found This -> " + s );
12- if ( s . equals ("lavaplayer" )) {
13- return List .of ("lavaplayer .natives" );
14- }
15- return List . of () ;
11+ return switch ( s ) {
12+ case "lavaplayer" -> List . of ("lavaplayer.natives" );
13+ case "opus.java" , "opus.java.api" -> List .of ("opus.java .natives" );
14+ default -> List . of ();
15+ } ;
1616 }
1717}
You can’t perform that action at this time.
0 commit comments