From 157d98d4b0ae98176222dc038dbdd2728cbccbe5 Mon Sep 17 00:00:00 2001 From: eueln Date: Tue, 21 Oct 2014 14:10:41 -0500 Subject: [PATCH] Store FScoreboards by FPlayer instead of Player --- .../factions/scoreboards/FScoreboard.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/main/java/com/massivecraft/factions/scoreboards/FScoreboard.java b/src/main/java/com/massivecraft/factions/scoreboards/FScoreboard.java index 7a8ed402..0cbd3b57 100644 --- a/src/main/java/com/massivecraft/factions/scoreboards/FScoreboard.java +++ b/src/main/java/com/massivecraft/factions/scoreboards/FScoreboard.java @@ -14,7 +14,7 @@ import java.util.HashMap; import java.util.Map; public class FScoreboard { - private static Map fscoreboards = new HashMap(); + private static Map fscoreboards = new HashMap(); private final Scoreboard scoreboard; private final FPlayer fplayer; @@ -26,22 +26,22 @@ public class FScoreboard { private boolean removed = false; public static void init(FPlayer fplayer) { - fscoreboards.put(fplayer.getPlayer(), new FScoreboard(fplayer)); + fscoreboards.put(fplayer, new FScoreboard(fplayer)); if (fplayer.hasFaction()) { FScoreboard.applyUpdates(fplayer.getFaction()); } } public static void remove(FPlayer fplayer) { - fscoreboards.remove(fplayer.getPlayer()).removed = true; + fscoreboards.remove(fplayer).removed = true; } - public static FScoreboard get(FPlayer player) { - return get(player.getPlayer()); + public static FScoreboard get(FPlayer fplayer) { + return fscoreboards.get(fplayer); } public static FScoreboard get(Player player) { - return fscoreboards.get(player); + return fscoreboards.get(FPlayers.i.get(player)); } public static void applyUpdatesLater(final Faction faction) {