Warning: session_start(): open(/var/lib/php/sessions/sess_gltkra82t2m8a1ij8cdg3pb626, O_RDWR) failed: No space left on device (28) in /var/www/tb-usercake/models/config.php on line 51
Warning: session_start(): Failed to read session data: files (path: /var/lib/php/sessions) in /var/www/tb-usercake/models/config.php on line 51
!7
//set flag DifferentJDA.
//lib 1400185 // discord with opus/JNA (hopefully not a problem)
import net.dv8tion.jda.core.managers.AudioManager; // Note: moved from core to api in JDA 4.0
import com.sedmelluq.discord.lavaplayer.player.*;
//lib 1400286 // lavaplayer 1.3.22
lib 1400288 // lavaplayer fat
lib 1400289 // httpclient
lib 1400290 // httpcore
lib 1400291 // commons-io
static AudioPlayerManager playerManager;
svoid cleanMeUp { dispose playerManager; }
cmodule DiscordAudioSpike > DynTalkBot2 {
S myName = "Discord Audio Spike";
start {
makeByServer = () -> new ByServer;
useAGIBlueForDropPunctuation = false;
preprocessAtSelfToMyName = false;
if (playerManager == null) playerManager = new DefaultAudioPlayerManager;
}
class ByServer extends DynTalkBot2.ByServer {
synchronized S processSimplifiedLine(S s, O... _) {
try answer super.processSimplifiedLine(s, _); // adding authorized users etc.
new Matches m;
if null (s = dropMyPrefixOrNull(s)) null;
optPar Message msg;
Guild guild = msg == null ? null : msg.getGuild();
if "voice channels"
ret str(guild.getVoiceChannels());
if "join voice channel"
ret joinVoiceChannel(first(guild.getVoiceChannels());
if (eqic(s, "help"))
ret ltrim([[
I'm a Discord Audio Test
[Bot made by https://BotCompany.de]
]]).replace("@me", atSelf());
null;
}
S joinVoiceChannel(VoiceChannel vc) {
if (vc == null) ret "No channel";
Guild guild = vc.getGuild();
AudioManager am = guild.getAudioManager();
am.openAudioConnection(vc);
ret "Audio connection to " + vc.getName() + " opened";
}
}
}