really fix it this time

This commit is contained in:
aPunch 2012-02-08 09:32:38 -06:00
parent 7c9c8dd546
commit 3d4aae4ca4
2 changed files with 1 additions and 3 deletions

View File

@ -120,8 +120,6 @@ public class NPCCommands {
public void renameNPC(CommandContext args, Player player, NPC npc) {
String oldName = npc.getName();
npc.setName(args.getString(1));
// Must reselect NPC after it is despawned
npcManager.selectNPC(player, npc);
Messaging.send(
player,
ChatColor.GREEN + "You renamed " + StringHelper.wrap(oldName) + " to "

View File

@ -52,7 +52,7 @@ public class CitizensNPCManager implements NPCManager {
public void despawn(NPC npc, boolean deselect) {
npc.getTrait(SpawnLocation.class).setLocation(npc.getBukkitEntity().getLocation());
if (deselect)
if (!deselect)
selected.removeAll(npc.getId());
npc.getBukkitEntity().remove();
}