Added option to randomize MAC address

This commit is contained in:
JKetelaar
2015-09-14 19:55:37 +02:00
parent 38a5910ad0
commit 6159f58814
5 changed files with 29 additions and 9 deletions
@@ -98,7 +98,7 @@ public class Script implements Runnable {
frameWorkType = TYPE_OTHER;
}
Core.verbose("Running script...");
Logger.addMessage("Script started.");
Logger.addMessage("Script started.", true);
try {
while(this.state != STATE_STOPPED) {
if(context.getRandomHandler().checkAndRun()) {
@@ -118,7 +118,7 @@ public class Script implements Runnable {
}
Core.verbose("Script stopped/finished, unloading and stopping...");
onFinish();
Logger.addMessage("Script stopped.");
Logger.addMessage("Script stopped.", false);
context.getServerProvider().unloadScript(this);
this.state = STATE_STOPPED;
context.setRunningScript(null);
@@ -90,7 +90,7 @@ public class RandomHandler {
public boolean checkAndRun() {
for(Random r : this.activeRandoms) {
if(r.activate()) {
Logger.addMessage("Running random '" + r.getName() + "'");
Logger.addMessage("Running random '" + r.getName() + "'", true);
r.execute();
return true;
}
@@ -70,7 +70,7 @@ public class UlirathaClient extends Thread {
case 75:
valid = stream.readBoolean();
if (valid) {
Logger.addMessage("We're connected with the Uliratha server!");
Logger.addMessage("We're connected with the Uliratha server!", false);
connected = true;
}else{
socket.close();
@@ -89,11 +89,11 @@ public class UlirathaClient extends Thread {
public void connectionBroken(NIOSocket nioSocket, Exception exception) {
if (valid) {
Logger.addMessage("We lost connection with the Uliratha server, reconnecting...");
Logger.addMessage("We lost connection with the Uliratha server, reconnecting...", false);
reconnect();
connected = false;
}else{
Logger.addMessage("We're disconnected from the Uliratha server");
Logger.addMessage("We're disconnected from the Uliratha server", false);
}
}
});