Clean this up a little bit

This commit is contained in:
TfT_02 2013-09-30 10:24:36 +02:00
parent 3a37d0e092
commit 6eb255632f
3 changed files with 8 additions and 7 deletions

View File

@ -1,6 +1,7 @@
package com.gmail.nossr50.commands.party;
import org.bukkit.ChatColor;
import org.bukkit.OfflinePlayer;
import org.bukkit.command.Command;
import org.bukkit.command.CommandExecutor;
import org.bukkit.command.CommandSender;
@ -43,12 +44,12 @@ public class PartyInfoCommand implements CommandExecutor {
StringBuilder memberList = new StringBuilder();
for (String memberName : playerParty.getMembers()) {
Player member = mcMMO.p.getServer().getPlayerExact(memberName);
OfflinePlayer member = mcMMO.p.getServer().getOfflinePlayer(memberName);
if (playerParty.getLeader().equalsIgnoreCase(memberName)) {
memberList.append(ChatColor.GOLD);
}
else if (member != null) {
else if (member.isOnline()) {
memberList.append(ChatColor.WHITE);
}
else {

View File

@ -22,7 +22,7 @@ public class PartyKickCommand implements CommandExecutor {
OfflinePlayer target = mcMMO.p.getServer().getOfflinePlayer(args[1]);
if (!playerParty.getMembers().contains(target.getName())) {
sender.sendMessage(LocaleLoader.getString("Party.NotInYourParty", args[1]));
sender.sendMessage(LocaleLoader.getString("Party.NotInYourParty", target.getName()));
return true;
}

View File

@ -67,14 +67,14 @@ public class Party {
return onlineMembers;
}
public String getLeader() {
return leader;
}
public String getName() {
return name;
}
public String getLeader() {
return leader;
}
public String getPassword() {
return password;
}