Add missing param in /remove

This commit is contained in:
KHobbits 2013-07-15 02:33:15 +01:00
parent 1f3e52a4b9
commit f6f71126a1
5 changed files with 21 additions and 5 deletions

View File

@ -6,6 +6,7 @@ import com.earth2me.essentials.utils.NumberUtil;
import java.lang.management.ManagementFactory;
import java.util.List;
import org.bukkit.ChatColor;
import org.bukkit.Chunk;
import org.bukkit.Server;
import org.bukkit.World;
import org.bukkit.command.CommandSender;
@ -55,8 +56,14 @@ public class Commandgc extends EssentialsCommand
worldType = "The End";
break;
}
int tileEntities = 0;
for (Chunk chunk : w.getLoadedChunks()) {
tileEntities += chunk.getTileEntities().length;
}
sender.sendMessage(_("gcWorld", worldType, w.getName(), w.getLoadedChunks().length, w.getEntities().size()));
sender.sendMessage(_("gcWorld", worldType, w.getName(), w.getLoadedChunks().length, w.getEntities().size(), tileEntities));
}
}
}

View File

@ -26,7 +26,8 @@ public class Commandremove extends EssentialsCommand
MINECARTS,
XP,
PAINTINGS,
ITEMFRAMES
ITEMFRAMES,
ENDERCRYSTALS
}
@Override
@ -178,6 +179,14 @@ public class Commandremove extends EssentialsCommand
removed++;
}
}
else if (toRemove == ToRemove.ENDERCRYSTALS)
{
if (e instanceof EnderCrystal)
{
e.remove();
removed++;
}
}
}
}
sender.sendMessage(_("removed", removed));

View File

@ -123,7 +123,7 @@ flying=flying
foreverAlone=\u00a74You have nobody to whom you can reply.
fullStack=\u00a74You already have a full stack.
gameMode=\u00a76Set game mode\u00a7c {0} \u00a76for {1}\u00a76.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76"\: \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76"\: \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities, \u00a7c{4}\u00a76 tiles.
gcfree=\u00a76Free memory\:\u00a7c {0} MB.
gcmax=\u00a76Maximum memory\:\u00a7c {0} MB.
gctotal=\u00a76Allocated memory\:\u00a7c {0} MB.

View File

@ -123,7 +123,7 @@ flying=flying
foreverAlone=\u00a74You have nobody to whom you can reply.
fullStack=\u00a74You already have a full stack.
gameMode=\u00a76Set game mode\u00a7c {0} \u00a76for {1}\u00a76.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76"\: \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities.
gcWorld=\u00a76{0} "\u00a7c{1}\u00a76"\: \u00a7c{2}\u00a76 chunks, \u00a7c{3}\u00a76 entities, \u00a7c{4}\u00a76 tiles.
gcfree=\u00a76Free memory\:\u00a7c {0} MB.
gcmax=\u00a76Maximum memory\:\u00a7c {0} MB.
gctotal=\u00a76Allocated memory\:\u00a7c {0} MB.

View File

@ -300,7 +300,7 @@ commands:
aliases: [formula,eformula,method,emethod,erecipe,recipes,erecipes]
remove:
description: Removes entities in your world.
usage: /<command> <drops|arrows|boats|minecarts|xp|paintings> [radius] [world]
usage: /<command> <drops|arrows|boats|minecarts|xp|paintings|itemframes|endercrystals> [radius] [world]
aliases: [eremove]
repair:
description: Repairs the durability of one or all items.