Fix crash rendering empty electric tool

This commit is contained in:
David Vierra 2017-01-20 21:18:42 -10:00
parent 340c617797
commit 2b80c158bc

View file

@ -511,11 +511,9 @@ public abstract class GT_MetaGenerated_Tool extends GT_MetaBase_Item implements
} }
public IToolStats getToolStats(ItemStack aStack) { public IToolStats getToolStats(ItemStack aStack) {
if(isItemStackUsable(aStack)) { // if(isItemStackUsable(aStack)) { // why?
return getToolStatsInternal(aStack); return getToolStatsInternal(aStack);
} }
return null;
}
private IToolStats getToolStatsInternal(ItemStack aStack) { private IToolStats getToolStatsInternal(ItemStack aStack) {
return aStack == null ? null : mToolStats.get((short) aStack.getItemDamage()); return aStack == null ? null : mToolStats.get((short) aStack.getItemDamage());