Probably, anyway, the crash didn't really make sense to begin with, but
this is written like 900x better anyhow.
This commit is contained in:
Shadows_of_Fire 2018-05-21 16:02:23 -04:00
parent 21f179aab4
commit 37753694f6

View file

@ -73,9 +73,7 @@ public class BlockWildPlant extends BlockBushBase{
@Override
public void getDrops(NonNullList<ItemStack> drops, IBlockAccess world, BlockPos pos, IBlockState state, int fortune){
int metadata = this.getMetaFromState(state);
if(metadata < ALL_WILD_PLANTS.length)
ALL_WILD_PLANTS[metadata].wildVersionOf.getDrops(drops, world, pos, ALL_WILD_PLANTS[metadata].wildVersionOf.getDefaultState().withProperty(BlockCrops.AGE, 7), fortune);
state.getValue(TYPE).wildVersionOf.getDrops(drops, world, pos, state, fortune);
}
@Override