Mirror von
https://github.com/IntellectualSites/FastAsyncWorldEdit.git
synchronisiert 2024-11-12 22:20:08 +01:00
Don't spam chat when a different type of vector is given to the Selector.
Dieser Commit ist enthalten in:
Ursprung
94dbfa3b85
Commit
ca06489e11
@ -80,7 +80,7 @@ public class CuboidRegionSelector implements RegionSelector, CUIRegion {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public boolean selectPrimary(Vector pos) {
|
public boolean selectPrimary(Vector pos) {
|
||||||
if (pos.equals(pos1)) {
|
if (pos1 != null && (pos.compareTo(pos1) == 0)) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -90,7 +90,7 @@ public class CuboidRegionSelector implements RegionSelector, CUIRegion {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public boolean selectSecondary(Vector pos) {
|
public boolean selectSecondary(Vector pos) {
|
||||||
if (pos.equals(pos2)) {
|
if (pos2 != null && (pos.compareTo(pos2)) == 0) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -90,7 +90,7 @@ public class CylinderRegionSelector implements RegionSelector, CUIRegion {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public boolean selectPrimary(Vector pos) {
|
public boolean selectPrimary(Vector pos) {
|
||||||
if (!region.getCenter().equals(new Vector(0, 0, 0)) && pos.equals(region.getCenter())) {
|
if (!region.getCenter().equals(new Vector(0, 0, 0)) && pos.compareTo(region.getCenter()) == 0) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -103,7 +103,7 @@ public class CylinderRegionSelector implements RegionSelector, CUIRegion {
|
|||||||
|
|
||||||
public boolean selectSecondary(Vector pos) {
|
public boolean selectSecondary(Vector pos) {
|
||||||
Vector center = region.getCenter();
|
Vector center = region.getCenter();
|
||||||
if (center.equals(new Vector(0, 0, 0))) {
|
if ((center.compareTo(new Vector(0, 0, 0))) == 0) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -58,7 +58,7 @@ public class ExtendingCuboidRegionSelector extends CuboidRegionSelector {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean selectPrimary(Vector pos) {
|
public boolean selectPrimary(Vector pos) {
|
||||||
if (pos.equals(pos1) && pos.equals(pos2)) {
|
if (pos1 != null && pos2 != null && pos.compareTo(pos1) == 0 && pos.compareTo(pos2) == 0) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren