Build script reformatting / 'Fixed' all unchecked warnings
This commit is contained in:
@@ -261,6 +261,7 @@ public class Administration{
|
||||
Settings.save();
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
private void load(){
|
||||
playerInfo = Settings.getObject("player-info", ObjectMap.class, ObjectMap::new);
|
||||
bannedIPs = Settings.getObject("banned-ips", Array.class, Array::new);
|
||||
|
||||
@@ -25,11 +25,11 @@ import java.io.IOException;
|
||||
|
||||
import static io.anuke.mindustry.Vars.*;
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
public class Net{
|
||||
private static boolean server;
|
||||
private static boolean active;
|
||||
private static boolean clientLoaded;
|
||||
private static String lastIP;
|
||||
private static Array<Object> packetQueue = new Array<>();
|
||||
private static ObjectMap<Class<?>, Consumer> clientListeners = new ObjectMap<>();
|
||||
private static ObjectMap<Class<?>, BiConsumer<Integer, Object>> serverListeners = new ObjectMap<>();
|
||||
@@ -106,7 +106,6 @@ public class Net{
|
||||
*/
|
||||
public static void connect(String ip, int port, Runnable success){
|
||||
try{
|
||||
lastIP = ip + ":" + port;
|
||||
if(!active){
|
||||
clientProvider.connect(ip, port, success);
|
||||
active = true;
|
||||
@@ -119,11 +118,6 @@ public class Net{
|
||||
}
|
||||
}
|
||||
|
||||
/**Returns the last IP connected to.*/
|
||||
public static String getLastIP() {
|
||||
return lastIP;
|
||||
}
|
||||
|
||||
/**
|
||||
* Host a server at an address.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user