From 0b489daf71b74aa663327cc9577a01c708487bf0 Mon Sep 17 00:00:00 2001 From: Frank Baumann Date: Mon, 21 Oct 2013 16:22:49 +0200 Subject: [PATCH] Cleanup for Broadcaster --- src/com/dre/managerxl/Broadcast.java | 2 +- src/com/dre/managerxl/MPlayer.java | 2 +- .../{player => }/BroadcastPlayerMsg.java | 3 +- .../broadcaster/player/BroadcastPlayer.java | 47 ------------------- 4 files changed, 3 insertions(+), 51 deletions(-) rename src/com/dre/managerxl/broadcaster/{player => }/BroadcastPlayerMsg.java (91%) delete mode 100644 src/com/dre/managerxl/broadcaster/player/BroadcastPlayer.java diff --git a/src/com/dre/managerxl/Broadcast.java b/src/com/dre/managerxl/Broadcast.java index d57c262..10f14a4 100644 --- a/src/com/dre/managerxl/Broadcast.java +++ b/src/com/dre/managerxl/Broadcast.java @@ -12,7 +12,7 @@ import org.bukkit.entity.Player; import com.dre.managerxl.broadcaster.BroadcastMsg; -import com.dre.managerxl.broadcaster.player.BroadcastPlayerMsg; +import com.dre.managerxl.broadcaster.BroadcastPlayerMsg; public class Broadcast { diff --git a/src/com/dre/managerxl/MPlayer.java b/src/com/dre/managerxl/MPlayer.java index 0e37103..62558a7 100644 --- a/src/com/dre/managerxl/MPlayer.java +++ b/src/com/dre/managerxl/MPlayer.java @@ -13,7 +13,7 @@ import org.bukkit.configuration.file.YamlConfiguration; import org.bukkit.entity.Player; -import com.dre.managerxl.broadcaster.player.BroadcastPlayerMsg; +import com.dre.managerxl.broadcaster.BroadcastPlayerMsg; public class MPlayer { private static Set mPlayers = new HashSet(); diff --git a/src/com/dre/managerxl/broadcaster/player/BroadcastPlayerMsg.java b/src/com/dre/managerxl/broadcaster/BroadcastPlayerMsg.java similarity index 91% rename from src/com/dre/managerxl/broadcaster/player/BroadcastPlayerMsg.java rename to src/com/dre/managerxl/broadcaster/BroadcastPlayerMsg.java index 33c38bb..9c46e6e 100644 --- a/src/com/dre/managerxl/broadcaster/player/BroadcastPlayerMsg.java +++ b/src/com/dre/managerxl/broadcaster/BroadcastPlayerMsg.java @@ -1,7 +1,6 @@ -package com.dre.managerxl.broadcaster.player; +package com.dre.managerxl.broadcaster; import com.dre.managerxl.MPlayer; -import com.dre.managerxl.broadcaster.BroadcastMsg; public class BroadcastPlayerMsg { diff --git a/src/com/dre/managerxl/broadcaster/player/BroadcastPlayer.java b/src/com/dre/managerxl/broadcaster/player/BroadcastPlayer.java deleted file mode 100644 index ea8d42b..0000000 --- a/src/com/dre/managerxl/broadcaster/player/BroadcastPlayer.java +++ /dev/null @@ -1,47 +0,0 @@ -/*package com.dre.managerxl.broadcaster.player; - -import java.util.ArrayList; -import java.util.HashMap; - -public class BroadcastPlayer { - - private String player; - public HashMap playerMsgs = new HashMap(); - - public static ArrayList list = new ArrayList(); - - public BroadcastPlayer(String player){ - list.add(this); - - this.player=player; - - - } - - public String getPlayer(){ - return player; - } - - public static BroadcastPlayer getBroadcastPlayer(String player){ - - for(BroadcastPlayer bPlayer: list){ - if(player.equalsIgnoreCase(bPlayer.getPlayer())){ - return bPlayer; - } - } - - return new BroadcastPlayer(player); // If not Exists create new one - } - - public BroadcastPlayerMsg getBMsg(int id) { - BroadcastPlayerMsg msg = playerMsgs.get(id); - - if(msg == null){ - msg = new BroadcastPlayerMsg(id, this); - } - - return msg; - } - -} -*/ \ No newline at end of file