Please stick to one way of destroying blocks
JrDemiurg opened this issue ยท 2 comments
In TremorzillaEntity.java breakBlocksInBoundingBox()
if (random.nextFloat() <= dropChance) {
level().destroyBlock(blockpos, true);
} else {
level().setBlockAndUpdate(blockpos, Blocks.AIR.defaultBlockState());
}
You're using 2 different methods to destroy blocks at the same time.
To avoid dropping it would be enough to call the level().destroyBlock(blockpos, false) method instead of replacing the block with air.
It's not a bug, but when I make a mixin to destroy blocks and use several different methods at the same time, it's inconvenient.
Thanks for your time <3
Also in breakBlocksAround() the same thing
if (random.nextFloat() <= dropChance && !nuke) {
level().destroyBlock(blockpos, true);
} else {
blockstate.onBlockExploded(level(), blockpos, dummyExplosion);
}
but there's another new method being used here for some reason...