diff --git a/buildcraft_resources/assets/buildcraft/lang/en_US.lang b/buildcraft_resources/assets/buildcraft/lang/en_US.lang index 84e5e070..40a7206b 100644 --- a/buildcraft_resources/assets/buildcraft/lang/en_US.lang +++ b/buildcraft_resources/assets/buildcraft/lang/en_US.lang @@ -19,6 +19,25 @@ buildcraft.boardRobotDelivery=Delivery buildcraft.boardRobotPump=Pump buildcraft.boardRobotStripes=Stripes +buildcraft.boardRobotPicker.desc=Picks up items +buildcraft.boardRobotLumberjack.desc=Breaks logs +buildcraft.boardRobotPlanter.desc=Plants crops +buildcraft.boardRobotLeaveCutter.desc=Cuts leaves +buildcraft.boardRobotCarrier.desc=Moves items between inventories +buildcraft.boardRobotFluidCarrier.desc=Moves fluids between tanks +buildcraft.boardRobotBomber.desc=Bombs locations +buildcraft.boardRobotKnight.desc=Fights mobs +buildcraft.boardRobotMiner.desc=Mines ores +buildcraft.boardRobotFarmer.desc=Farms animals +buildcraft.boardRobotHarvester.desc=Harvests mature crops +buildcraft.boardRobotShovelman.desc=Shovels area +buildcraft.boardRobotButcher.desc=Fights animals +buildcraft.boardRobotBuilder.desc=Builds structures +buildcraft.boardRobotCrafter.desc=Crafts items +buildcraft.boardRobotDelivery.desc=Delivers items upon request +buildcraft.boardRobotPump.desc=Pumps out liquids +buildcraft.boardRobotStripes.desc=Uhh... Stripes! + chat.gateCopier.clear=Gate information cleared. chat.gateCopier.gateCopied=Copied gate information to copier. chat.gateCopier.gatePasted=Pasted copied data to gate. diff --git a/buildcraft_resources/changelog/7.0.3 b/buildcraft_resources/changelog/7.0.3 new file mode 100644 index 00000000..c0abd6ea --- /dev/null +++ b/buildcraft_resources/changelog/7.0.3 @@ -0,0 +1,7 @@ +Everything from BuildCraft 6.4.14, and: + +Improvements: +* [#2672] Add tooltips to robots and color-code energy information (asie) + +Bugs fixed: +* Erratic robot recharge (hea3ven) diff --git a/common/buildcraft/robotics/ItemRobot.java b/common/buildcraft/robotics/ItemRobot.java index f9216827..01b1ae80 100755 --- a/common/buildcraft/robotics/ItemRobot.java +++ b/common/buildcraft/robotics/ItemRobot.java @@ -16,6 +16,7 @@ import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; +import net.minecraft.util.EnumChatFormatting; import net.minecraft.util.ResourceLocation; import net.minecraft.world.World; import cpw.mods.fml.common.FMLCommonHandler; @@ -95,10 +96,18 @@ public class ItemRobot extends ItemBuildCraft implements IEnergyContainerItem { if (nbt != null) { nbt.addInformation(stack, player, list, advanced); } - } - int energy = NBTUtils.getItemData(stack).getInteger("energy"); - list.add(energy + "/" + EntityRobotBase.MAX_ENERGY + " RF"); + int energy = NBTUtils.getItemData(stack).getInteger("energy"); + int pct = (energy * 100 / EntityRobotBase.MAX_ENERGY); + String enInfo = pct + "% Charged"; + if (energy == EntityRobotBase.MAX_ENERGY) { + enInfo = "Full Charge"; + } else if (energy == 0) { + enInfo = "No Charge"; + } + enInfo = (pct >= 80 ? EnumChatFormatting.GREEN : (pct >= 50 ? EnumChatFormatting.YELLOW : (pct >= 30 ? EnumChatFormatting.GOLD : (pct >= 20 ? EnumChatFormatting.RED : EnumChatFormatting.DARK_RED)))) + enInfo; + list.add(enInfo); + } } @Override diff --git a/common/buildcraft/robotics/boards/BCBoardNBT.java b/common/buildcraft/robotics/boards/BCBoardNBT.java index 5b943774..023bf348 100644 --- a/common/buildcraft/robotics/boards/BCBoardNBT.java +++ b/common/buildcraft/robotics/boards/BCBoardNBT.java @@ -8,6 +8,7 @@ import net.minecraft.client.renderer.texture.IIconRegister; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; +import net.minecraft.util.EnumChatFormatting; import net.minecraft.util.IIcon; import net.minecraft.util.ResourceLocation; import cpw.mods.fml.relauncher.Side; @@ -54,7 +55,8 @@ public class BCBoardNBT extends RedstoneBoardRobotNBT { @Override public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean advanced) { - list.add(StringUtils.localize("buildcraft.boardRobot" + upperName)); + list.add(EnumChatFormatting.BOLD + StringUtils.localize("buildcraft.boardRobot" + upperName)); + list.add(StringUtils.localize("buildcraft.boardRobot" + upperName + ".desc")); } @Override