Skip to content

Commit

Permalink
Address vector deprecations
Browse files Browse the repository at this point in the history
  • Loading branch information
dordsor21 committed Sep 26, 2024
1 parent 34009d1 commit c2e3a4e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -994,7 +994,7 @@ public <V extends Future<V>> V call(final IChunkSet set, final Runnable finalize
tiles.entrySet().removeIf(e -> {
BlockVector3 pos = e.getKey();
return set
.getBlock(pos.getBlockX(), pos.getBlockY(), pos.getBlockZ())
.getBlock(pos.x(), pos.y(), pos.z())
.getOrdinalChar() != BlockTypesCache.ReservedIDs.__RESERVED__;
});
for (int layer = set.getMinSectionPosition(); layer <= set.getMaxSectionPosition(); layer++) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ public WorldRegionsRegion(@Nonnull final MCAWorld world) {
public Iterator<BlockVector3> iterator() {
Queue<BlockVector2> queue = new ArrayDeque<>(getChunks());
return new Iterator<>() {
private final int by = min.getY();
private final int ty = max.getY();
private final int by = min.y();
private final int ty = max.y();
private final MutableBlockVector3 mutable = new MutableBlockVector3();

private BlockVector2 chunk = queue.poll();
Expand Down Expand Up @@ -156,7 +156,7 @@ public int getWidth() {
BlockVector3 min = getMinimumPoint();
BlockVector3 max = getMaximumPoint();

return max.getX() - min.getX() + 1;
return max.x() - min.x() + 1;
}

/**
Expand All @@ -169,7 +169,7 @@ public int getHeight() {
BlockVector3 min = getMinimumPoint();
BlockVector3 max = getMaximumPoint();

return max.getY() - min.getY() + 1;
return max.y() - min.y() + 1;
}

/**
Expand All @@ -182,7 +182,7 @@ public int getLength() {
BlockVector3 min = getMinimumPoint();
BlockVector3 max = getMaximumPoint();

return max.getZ() - min.getZ() + 1;
return max.z() - min.z() + 1;
}

@Override
Expand Down Expand Up @@ -233,8 +233,8 @@ public Iterator<BlockVector3> iterator() {

return new Iterator<>() {
private final MutableBlockVector3 mutable = new MutableBlockVector3();
private final int by = min.getY() >> 4;
private final int ty = max.getY() >> 4;
private final int by = min.y() >> 4;
private final int ty = max.y() >> 4;

private BlockVector2 chunk = chunks.poll();
private int y;
Expand Down Expand Up @@ -267,7 +267,7 @@ public Throwable fillInStackTrace() {

@Override
public int size() {
return getChunks().size() * ((max.getY() >> 4) - (min.getY() >> 4));
return getChunks().size() * ((max.y() >> 4) - (min.y() >> 4));
}
};
}
Expand Down

0 comments on commit c2e3a4e

Please sign in to comment.