use of net.minecraft.util.ChatComponentText in project LogisticsPipes by RS485.
the class ClearCommand method executeCommand.
@Override
public void executeCommand(ICommandSender sender, String[] args) {
if (args.length <= 0 || !args[0].equalsIgnoreCase("all")) {
sender.addChatMessage(new ChatComponentText("%LPSTORESENDMESSAGE%"));
sender.addChatMessage(new ChatComponentText("%LPCLEARCHAT%"));
sender.addChatMessage(new ChatComponentText("%LPRESTORESENDMESSAGE%"));
} else {
sender.addChatMessage(new ChatComponentText("%LPCLEARCHAT%"));
}
}
use of net.minecraft.util.ChatComponentText in project LogisticsPipes by RS485.
the class NameLookupCommand method executeCommand.
@Override
public void executeCommand(ICommandSender sender, String[] args) {
if (args.length < 2) {
throw new MissingArgumentException();
}
String idString = args[0];
String metaString = args[1];
int id = Integer.valueOf(idString);
int meta = Integer.valueOf(metaString);
ItemIdentifier item = ItemIdentifier.get(Item.getItemById(id), meta, null);
sender.addChatMessage(new ChatComponentText("Name: " + item.getFriendlyNameCC()));
}
use of net.minecraft.util.ChatComponentText in project LogisticsPipes by RS485.
the class TransferNamesCommand method executeCommand.
@Override
public void executeCommand(ICommandSender sender, String[] args) {
sender.addChatMessage(new ChatComponentText("Requesting Transfer"));
MainProxy.sendPacketToPlayer(PacketHandler.getPacket(RequestUpdateNamesPacket.class), (EntityPlayer) sender);
MainProxy.proxy.sendNameUpdateRequest((EntityPlayer) sender);
}
use of net.minecraft.util.ChatComponentText in project LogisticsPipes by RS485.
the class VersionCommand method executeCommand.
@Override
public void executeCommand(ICommandSender sender, String[] args) {
sender.addChatMessage(new ChatComponentText(String.format("LogisticsPipes %s for Minecraft %s.", LogisticsPipes.class.getAnnotation(Mod.class).version(), LPConstants.MCVersion)));
VersionChecker versionChecker = LogisticsPipes.versionChecker;
sender.addChatMessage(new ChatComponentText(versionChecker.getVersionCheckerStatus()));
if (versionChecker.isVersionCheckDone() && versionChecker.getVersionInfo().isNewVersionAvailable()) {
sender.addChatMessage(new ChatComponentText("Use \"/logisticspipes changelog\" to see a changelog."));
}
}
use of net.minecraft.util.ChatComponentText in project LogisticsPipes by RS485.
the class PipeDebugLogResponse method processPacket.
@Override
public void processPacket(EntityPlayer player) {
LogisticsTileGenericPipe tile = this.getPipe(player.getEntityWorld());
if (tile != null) {
((CoreRoutedPipe) tile.pipe).debug.openForPlayer(player);
player.addChatComponentMessage(new ChatComponentText("Debug log enabled."));
}
}
Aggregations