set harvest level for all tool types

This commit is contained in:
Ellpeck 2017-04-05 05:13:50 +02:00
parent 2d5b8c1d92
commit 0e1a4c94be

View file

@ -45,7 +45,7 @@ public class ItemAllToolAA extends ItemToolAA implements IColorProvidingItem{
this.color = color;
this.setMaxDamage(this.getMaxDamage()*4);
this.setHarvestLevel("pickaxe", toolMat.getHarvestLevel());
this.setHarvestLevels(toolMat.getHarvestLevel());
}
public ItemAllToolAA(ToolMaterial toolMat, ItemStack repairItem, String unlocalizedName, EnumRarity rarity, int color){
@ -53,7 +53,13 @@ public class ItemAllToolAA extends ItemToolAA implements IColorProvidingItem{
this.color = color;
this.setMaxDamage(this.getMaxDamage()*4);
this.setHarvestLevel("pickaxe", toolMat.getHarvestLevel());
this.setHarvestLevels(toolMat.getHarvestLevel());
}
private void setHarvestLevels(int amount){
for(String s : this.getToolClasses(null)){
this.setHarvestLevel(s, amount);
}
}
@Override