fixed decayed leaves not decaying

closes #376
This commit is contained in:
Ell 2024-12-05 22:27:22 +01:00
parent 96cd5963f5
commit fd52a3a27d

View file

@ -17,7 +17,7 @@ public class BlockDecayedLeaves extends BlockImpl implements ICustomBlockState {
@Override @Override
@SuppressWarnings("deprecation") @SuppressWarnings("deprecation")
public void tick(BlockState state, ServerLevel level, BlockPos pos, RandomSource random) { public void randomTick(BlockState state, ServerLevel level, BlockPos pos, RandomSource random) {
if (!level.isClientSide) { if (!level.isClientSide) {
level.setBlockAndUpdate(pos, Blocks.AIR.defaultBlockState()); level.setBlockAndUpdate(pos, Blocks.AIR.defaultBlockState());
} }
@ -27,4 +27,5 @@ public class BlockDecayedLeaves extends BlockImpl implements ICustomBlockState {
public void generateCustomBlockState(BlockStateGenerator generator) { public void generateCustomBlockState(BlockStateGenerator generator) {
generator.simpleBlock(this, generator.models().getExistingFile(generator.modLoc(this.getBaseName()))); generator.simpleBlock(this, generator.models().getExistingFile(generator.modLoc(this.getBaseName())));
} }
} }