mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-02 04:56:50 +01:00
Fixed a bunch of warnings.
This commit is contained in:
parent
ce271f8abc
commit
32224b916d
5 changed files with 24 additions and 30 deletions
|
@ -2,8 +2,6 @@ package net.minecraft.server;
|
||||||
|
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.IOException;
|
|
||||||
import java.io.PrintStream;
|
|
||||||
import java.net.InetAddress;
|
import java.net.InetAddress;
|
||||||
import java.net.UnknownHostException;
|
import java.net.UnknownHostException;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
@ -11,7 +9,6 @@ import java.util.Collections;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Set;
|
|
||||||
import java.util.logging.Level;
|
import java.util.logging.Level;
|
||||||
import java.util.logging.Logger;
|
import java.util.logging.Logger;
|
||||||
|
|
||||||
|
@ -22,7 +19,7 @@ public class MinecraftServer
|
||||||
implements ICommandListener, Runnable {
|
implements ICommandListener, Runnable {
|
||||||
|
|
||||||
public static Logger a = Logger.getLogger("Minecraft");
|
public static Logger a = Logger.getLogger("Minecraft");
|
||||||
public static HashMap b = new HashMap();
|
public static HashMap<String, Integer> b = new HashMap<String, Integer>();
|
||||||
public NetworkListenThread c;
|
public NetworkListenThread c;
|
||||||
public PropertyManager d;
|
public PropertyManager d;
|
||||||
public WorldServer e;
|
public WorldServer e;
|
||||||
|
@ -32,8 +29,8 @@ implements ICommandListener, Runnable {
|
||||||
int h;
|
int h;
|
||||||
public String i;
|
public String i;
|
||||||
public int j;
|
public int j;
|
||||||
private List p;
|
private List<IUpdatePlayerListBox> p;
|
||||||
private List q;
|
private List<ServerCommand> q;
|
||||||
public EntityTracker k;
|
public EntityTracker k;
|
||||||
public boolean l;
|
public boolean l;
|
||||||
public boolean m;
|
public boolean m;
|
||||||
|
@ -45,8 +42,8 @@ implements ICommandListener, Runnable {
|
||||||
o = true;
|
o = true;
|
||||||
g = false;
|
g = false;
|
||||||
h = 0;
|
h = 0;
|
||||||
p = new ArrayList();
|
p = new ArrayList<IUpdatePlayerListBox>();
|
||||||
q = Collections.synchronizedList(new ArrayList());
|
q = Collections.synchronizedList(new ArrayList<ServerCommand>());
|
||||||
new ThreadSleepForever(this);
|
new ThreadSleepForever(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -212,9 +209,9 @@ implements ICommandListener, Runnable {
|
||||||
}
|
}
|
||||||
|
|
||||||
private void h() {
|
private void h() {
|
||||||
ArrayList arraylist = new ArrayList();
|
ArrayList<String> arraylist = new ArrayList<String>();
|
||||||
|
|
||||||
for (Iterator iterator = b.keySet().iterator(); iterator.hasNext();) {
|
for (Iterator<String> iterator = b.keySet().iterator(); iterator.hasNext();) {
|
||||||
String s = (String) iterator.next();
|
String s = (String) iterator.next();
|
||||||
int k1 = ((Integer) b.get(s)).intValue();
|
int k1 = ((Integer) b.get(s)).intValue();
|
||||||
|
|
||||||
|
|
|
@ -1,11 +1,9 @@
|
||||||
package net.minecraft.server;
|
package net.minecraft.server;
|
||||||
|
|
||||||
|
|
||||||
import java.io.PrintStream;
|
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
import java.util.logging.Logger;
|
import java.util.logging.Logger;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.Player;
|
|
||||||
import org.bukkit.craftbukkit.CraftPlayer;
|
import org.bukkit.craftbukkit.CraftPlayer;
|
||||||
import org.bukkit.craftbukkit.CraftServer;
|
import org.bukkit.craftbukkit.CraftServer;
|
||||||
import org.bukkit.event.Event.Type;
|
import org.bukkit.event.Event.Type;
|
||||||
|
@ -26,7 +24,7 @@ implements ICommandListener {
|
||||||
private double h;
|
private double h;
|
||||||
private double i;
|
private double i;
|
||||||
private boolean j;
|
private boolean j;
|
||||||
private Map k;
|
private Map<Integer, Short> k;
|
||||||
|
|
||||||
// CraftBukkit - next 2 lines
|
// CraftBukkit - next 2 lines
|
||||||
private final CraftServer server;
|
private final CraftServer server;
|
||||||
|
@ -36,7 +34,7 @@ implements ICommandListener {
|
||||||
c = false;
|
c = false;
|
||||||
f = 0;
|
f = 0;
|
||||||
j = true;
|
j = true;
|
||||||
k = new HashMap();
|
k = new HashMap<Integer, Short>();
|
||||||
d = minecraftserver;
|
d = minecraftserver;
|
||||||
b = networkmanager;
|
b = networkmanager;
|
||||||
networkmanager.a(this);
|
networkmanager.a(this);
|
||||||
|
@ -506,7 +504,7 @@ implements ICommandListener {
|
||||||
k.put(Integer.valueOf(e.ap.f), Short.valueOf(packet102.d));
|
k.put(Integer.valueOf(e.ap.f), Short.valueOf(packet102.d));
|
||||||
e.a.b(new Packet106(packet102.a, packet102.d, false));
|
e.a.b(new Packet106(packet102.a, packet102.d, false));
|
||||||
e.ap.a(e, false);
|
e.ap.a(e, false);
|
||||||
ArrayList arraylist = new ArrayList();
|
ArrayList<ItemStack> arraylist = new ArrayList<ItemStack>();
|
||||||
|
|
||||||
for (int l = 0; l < e.ap.e.size(); l++) {
|
for (int l = 0; l < e.ap.e.size(); l++) {
|
||||||
arraylist.add(((Slot) e.ap.e.get(l)).c());
|
arraylist.add(((Slot) e.ap.e.get(l)).c());
|
||||||
|
|
|
@ -14,13 +14,13 @@ import org.bukkit.event.player.PlayerLoginEvent;
|
||||||
public class ServerConfigurationManager {
|
public class ServerConfigurationManager {
|
||||||
|
|
||||||
public static Logger a = Logger.getLogger("Minecraft");
|
public static Logger a = Logger.getLogger("Minecraft");
|
||||||
public List b;
|
public List<EntityPlayerMP> b;
|
||||||
private MinecraftServer c;
|
private MinecraftServer c;
|
||||||
private PlayerManager d;
|
private PlayerManager d;
|
||||||
private int e;
|
private int e;
|
||||||
private Set f;
|
private Set<String> f;
|
||||||
private Set g;
|
private Set<String> g;
|
||||||
private Set h;
|
private Set<String> h;
|
||||||
private File i;
|
private File i;
|
||||||
private File j;
|
private File j;
|
||||||
private File k;
|
private File k;
|
||||||
|
@ -30,10 +30,10 @@ public class ServerConfigurationManager {
|
||||||
public ServerConfigurationManager(MinecraftServer minecraftserver) {
|
public ServerConfigurationManager(MinecraftServer minecraftserver) {
|
||||||
server = minecraftserver.server; // Craftbukkit
|
server = minecraftserver.server; // Craftbukkit
|
||||||
|
|
||||||
b = new ArrayList();
|
b = new ArrayList<EntityPlayerMP>();
|
||||||
f = new HashSet();
|
f = new HashSet<String>();
|
||||||
g = new HashSet();
|
g = new HashSet<String>();
|
||||||
h = new HashSet();
|
h = new HashSet<String>();
|
||||||
c = minecraftserver;
|
c = minecraftserver;
|
||||||
i = minecraftserver.a("banned-players.txt");
|
i = minecraftserver.a("banned-players.txt");
|
||||||
j = minecraftserver.a("banned-ips.txt");
|
j = minecraftserver.a("banned-ips.txt");
|
||||||
|
@ -205,7 +205,7 @@ public class ServerConfigurationManager {
|
||||||
PrintWriter printwriter = new PrintWriter(new FileWriter(i, false));
|
PrintWriter printwriter = new PrintWriter(new FileWriter(i, false));
|
||||||
String s;
|
String s;
|
||||||
|
|
||||||
for (Iterator iterator = f.iterator(); iterator.hasNext(); printwriter.println(s)) {
|
for (Iterator<String> iterator = f.iterator(); iterator.hasNext(); printwriter.println(s)) {
|
||||||
s = (String) iterator.next();
|
s = (String) iterator.next();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -245,7 +245,7 @@ public class ServerConfigurationManager {
|
||||||
PrintWriter printwriter = new PrintWriter(new FileWriter(j, false));
|
PrintWriter printwriter = new PrintWriter(new FileWriter(j, false));
|
||||||
String s;
|
String s;
|
||||||
|
|
||||||
for (Iterator iterator = g.iterator(); iterator.hasNext(); printwriter.println(s)) {
|
for (Iterator<String> iterator = g.iterator(); iterator.hasNext(); printwriter.println(s)) {
|
||||||
s = (String) iterator.next();
|
s = (String) iterator.next();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -285,7 +285,7 @@ public class ServerConfigurationManager {
|
||||||
PrintWriter printwriter = new PrintWriter(new FileWriter(k, false));
|
PrintWriter printwriter = new PrintWriter(new FileWriter(k, false));
|
||||||
String s;
|
String s;
|
||||||
|
|
||||||
for (Iterator iterator = h.iterator(); iterator.hasNext(); printwriter.println(s)) {
|
for (Iterator<String> iterator = h.iterator(); iterator.hasNext(); printwriter.println(s)) {
|
||||||
s = (String) iterator.next();
|
s = (String) iterator.next();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,6 @@ import java.util.Random;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import org.bukkit.Material;
|
|
||||||
import org.bukkit.craftbukkit.CraftServer;
|
import org.bukkit.craftbukkit.CraftServer;
|
||||||
import org.bukkit.craftbukkit.CraftWorld;
|
import org.bukkit.craftbukkit.CraftWorld;
|
||||||
import org.bukkit.event.Event;
|
import org.bukkit.event.Event;
|
||||||
|
@ -127,8 +126,8 @@ public class WorldServer extends World {
|
||||||
return A;
|
return A;
|
||||||
}
|
}
|
||||||
|
|
||||||
public List d(int i, int j, int k, int l, int i1, int j1) {
|
public List<TileEntity> d(int i, int j, int k, int l, int i1, int j1) {
|
||||||
ArrayList arraylist = new ArrayList();
|
ArrayList<TileEntity> arraylist = new ArrayList<TileEntity>();
|
||||||
|
|
||||||
for (int k1 = 0; k1 < c.size(); k1++) {
|
for (int k1 = 0; k1 < c.size(); k1++) {
|
||||||
TileEntity tileentity = (TileEntity) c.get(k1);
|
TileEntity tileentity = (TileEntity) c.get(k1);
|
||||||
|
|
Loading…
Reference in a new issue