From f91fab7bd3134054df26b9345adaf0053c2e39c6 Mon Sep 17 00:00:00 2001 From: Mike Primm Date: Wed, 24 Jul 2013 21:43:41 -0500 Subject: [PATCH] Fix grouping of players in unaffiliated factions (Wilderness/None) - shouldn't see each other --- .../java/org/dynmap/factions/DynmapFactionsPlugin.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/main/java/org/dynmap/factions/DynmapFactionsPlugin.java b/src/main/java/org/dynmap/factions/DynmapFactionsPlugin.java index 7656c17..cb919c3 100644 --- a/src/main/java/org/dynmap/factions/DynmapFactionsPlugin.java +++ b/src/main/java/org/dynmap/factions/DynmapFactionsPlugin.java @@ -170,8 +170,8 @@ public class DynmapFactionsPlugin extends JavaPlugin { } private void updatePlayerSet(String univid, String factid) { - /* If Wilderness or other unassociated factions, skip */ - if(factid.equals("0") || factid.startsWith("-")) { + /* If Wilderness or other unassociated factions (guid-style ID), skip */ + if(factid.indexOf('-') >= 0) { return; } Set plids = new HashSet(); @@ -551,6 +551,9 @@ public class DynmapFactionsPlugin extends JavaPlugin { if(playersets) { for (FactionColl fc : FactionColls.get().getColls()) { for(Faction f : fc.getAll()) { + if ((f == fc.getNone()) || (f == fc.getWarzone()) || (f == fc.getSafezone())) { + continue; + } updatePlayerSet(fc.getUniverse(), f.getId()); } }