Skip to content

Commit 2ffc73b

Browse files
committed
Fix EllipseMask ignoring center-position when testing
1 parent 7b9057c commit 2ffc73b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

core/src/main/java/de/bluecolored/bluemap/core/map/mask/EllipseMask.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,8 @@ public boolean test(int x, int y, int z) {
5858
}
5959

6060
public boolean testXZ(double x, double z) {
61+
x = x - center.getX();
62+
z = z - center.getY();
6163
return (x * x) / radiusSquaredX + (z * z) / radiusSquaredZ <= 1.0;
6264
}
6365

0 commit comments

Comments
 (0)