Closed DG5S closed 3 years ago
It is as the Error states "TS3Config cannot be modified after being used to create a TS3Query. Please make any changes to TS3Config before calling TS3Query's constructor"
You can't change the Configuration
config.setHost("127.0.0.1");
config.setFloodRate(FloodRate.UNLIMITED);
AFTER you construct the Query object
do something like this (I don't have an IDE at hand) and it should work:
public class Main {
public static final TS3Config config = new TS3Config();
public static void main(String[] args) {
config.setHost("127.0.0.1");
config.setFloodRate(FloodRate.UNLIMITED);
TS3Query query = new TS3Query(config);
query.connect();
TS3Api api = query.getApi();
api.login("serveradmin", "serverpassword");
api.selectVirtualServerByPort(9987);
api.setNickname("TS3-Manager");
}
}
Okay I will try it
It works, thank uuuu so. I try my best to create a good Bot for us all.
Just a Tip: Maybe get comfortable with the Basics of Java Programming before you start such a Project. There is quite the good Literature out there
I programmed Java 3 years ago and I try new stuff
Hey, I started programming my Bot and on the first start I get this Error. What did I wrong.
Error:
My written Code:
What can I do to fix that Problem. I have written the right serverpassword and the right host ip. I changed it here because of secret Informations.
This is the Tutorial I use.