mirror of
https://github.com/GTNewHorizons/ForestryMC.git
synced 2026-11-19 11:49:14 +00:00
Add tooltip for grafter use count on a new grafter
This commit is contained in:
1 parent
0b86b3df8f
commit
bb477f0dfb
3 files changed
+13
-2
No files matched your search
@@ -57,7 +57,7 @@ public class ItemHiveFrame extends ItemForestry implements IHiveFrame {
|
||||
super.addInformation(stack, playerIn, tooltip, advanced);
|
||||
beeModifier.addInformation(stack, playerIn, tooltip, advanced);
|
||||
if (!stack.isItemDamaged()) {
|
||||
tooltip.add(Translator.translateToLocalFormatted("item.for.frame.durability", stack.getMaxDamage()));
|
||||
tooltip.add(Translator.translateToLocalFormatted("item.for.durability", stack.getMaxDamage()));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -10,6 +10,9 @@
|
||||
******************************************************************************/
|
||||
package forestry.arboriculture.items;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import forestry.core.utils.Translator;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.BlockLeaves;
|
||||
import net.minecraft.block.material.Material;
|
||||
@@ -34,6 +37,14 @@ public class ItemGrafter extends ItemForestryTool implements IToolGrafter {
|
||||
setEfficiencyOnProperMaterial(4.0f);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addInformation(ItemStack stack, EntityPlayer playerIn, List<String> tooltip, boolean advanced) {
|
||||
super.addInformation(stack, playerIn, tooltip, advanced);
|
||||
if (!stack.isItemDamaged()) {
|
||||
tooltip.add(Translator.translateToLocalFormatted("item.for.uses", stack.getMaxDamage() + 1));
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canHarvestBlock(IBlockState state, ItemStack stack) {
|
||||
Block block = state.getBlock();
|
||||
|
||||
Reference in new issue
Block a user