fix #2320 - Add null check for blockstate for effective override
This commit is contained in:
parent
ea0db38b6a
commit
49a1cc1619
1 changed files with 4 additions and 0 deletions
|
@ -82,6 +82,10 @@ public class DrillItem extends PickaxeItem implements EnergyHolder, ItemDurabili
|
||||||
// PickaxeItem
|
// PickaxeItem
|
||||||
@Override
|
@Override
|
||||||
public boolean isEffectiveOn(BlockState blockIn) {
|
public boolean isEffectiveOn(BlockState blockIn) {
|
||||||
|
if(blockIn == null){
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if (Items.DIAMOND_PICKAXE.isEffectiveOn(blockIn)) {
|
if (Items.DIAMOND_PICKAXE.isEffectiveOn(blockIn)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue