Renamed method argument l to location in LocationUtils#isInArea

This commit is contained in:
Christian Koop 2023-06-29 09:37:42 +02:00
parent 0d1bd6075d
commit 9ac1da984d
No known key found for this signature in database
GPG Key ID: 89A8181384E010A3

View File

@ -12,7 +12,7 @@ public class LocationUtils {
location1.getBlockZ() == location2.getBlockZ();
}
public static boolean isInArea(Location l, Location pos1, Location pos2) {
public static boolean isInArea(Location location, Location pos1, Location pos2) {
double x1 = Math.min(pos1.getX(), pos2.getX());
double y1 = Math.min(pos1.getY(), pos2.getY());
double z1 = Math.min(pos1.getZ(), pos2.getZ());
@ -21,8 +21,8 @@ public class LocationUtils {
double y2 = Math.max(pos1.getY(), pos2.getY());
double z2 = Math.max(pos1.getZ(), pos2.getZ());
return l.getX() >= x1 && l.getX() <= x2 &&
l.getY() >= y1 && l.getY() <= y2 &&
l.getZ() >= z1 && l.getZ() <= z2;
return location.getX() >= x1 && location.getX() <= x2 &&
location.getY() >= y1 && location.getY() <= y2 &&
location.getZ() >= z1 && location.getZ() <= z2;
}
}