This commit is contained in:
Jesse Boyd
2019-06-29 04:20:48 +10:00
parent f1e98da01f
commit 58c6b6278f
12 changed files with 121 additions and 61 deletions

View File

@@ -68,11 +68,10 @@ public class AreaPickaxe implements BlockTool {
for (int x = ox - range; x <= ox + range; ++x) {
for (int z = oz - range; z <= oz + range; ++z) {
for (int y = oy + range; y >= oy - range; --y) {
BlockVector3 pos = BlockVector3.at(x, y, z);
if (editSession.getLazyBlock(pos).getBlockType() != initialType) {
if (editSession.getLazyBlock(x, y, z).getBlockType() != initialType) {
continue;
}
editSession.setBlock(pos, BlockTypes.AIR.getDefaultState());
editSession.setBlock(x, y, z, BlockTypes.AIR.getDefaultState());
}
}
}