Entity tracking and invalid world detection

This commit is contained in:
boy0001 2015-03-12 19:52:26 +11:00
parent 12f024664a
commit 1f8702f072
4 changed files with 79 additions and 3 deletions

View file

@ -136,8 +136,10 @@ public class PlotSquared {
public static Set<Plot> getPlots() {
final ArrayList<Plot> newplots = new ArrayList<>();
for (final HashMap<PlotId, Plot> world : plots.values()) {
newplots.addAll(world.values());
for (final Entry<String, HashMap<PlotId, Plot>> entry : plots.entrySet()) {
if (isPlotWorld(entry.getKey())) {
newplots.addAll(entry.getValue().values());
}
}
return new LinkedHashSet<>(newplots);
}