Mirror von
https://github.com/IntellectualSites/FastAsyncWorldEdit.git
synchronisiert 2024-11-10 05:20:04 +01:00
Fixed //replace. Closes #1069
Dieser Commit ist enthalten in:
Ursprung
da6ccd1f98
Commit
0bea058328
@ -1275,18 +1275,10 @@ public class EditSession {
|
|||||||
for (int z = minZ; z <= maxZ; ++z) {
|
for (int z = minZ; z <= maxZ; ++z) {
|
||||||
Vector pt = new Vector(x, y, z);
|
Vector pt = new Vector(x, y, z);
|
||||||
BaseBlock curBlockType = getBlock(pt);
|
BaseBlock curBlockType = getBlock(pt);
|
||||||
|
|
||||||
if (definiteBlockTypes == null) {
|
|
||||||
//replace <to-block>
|
|
||||||
if (curBlockType.isAir()) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
//replace <from-block> <to-block>
|
//replace <from-block> <to-block>
|
||||||
if (!definiteBlockTypes.contains(curBlockType) && fuzzyBlockTypes.contains(curBlockType.getType())) {
|
if (!definiteBlockTypes.contains(curBlockType) && !fuzzyBlockTypes.contains(curBlockType.getType())) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if (setBlock(pt, toBlock)) {
|
if (setBlock(pt, toBlock)) {
|
||||||
++affected;
|
++affected;
|
||||||
@ -1298,17 +1290,10 @@ public class EditSession {
|
|||||||
for (Vector pt : region) {
|
for (Vector pt : region) {
|
||||||
BaseBlock curBlockType = getBlock(pt);
|
BaseBlock curBlockType = getBlock(pt);
|
||||||
|
|
||||||
if (definiteBlockTypes == null) {
|
|
||||||
//replace <to-block>
|
|
||||||
if (curBlockType.isAir()) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
//replace <from-block> <to-block>
|
//replace <from-block> <to-block>
|
||||||
if (!definiteBlockTypes.contains(curBlockType) && fuzzyBlockTypes.contains(curBlockType.getType())) {
|
if (!definiteBlockTypes.contains(curBlockType) && !fuzzyBlockTypes.contains(curBlockType.getType())) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if (setBlock(pt, toBlock)) {
|
if (setBlock(pt, toBlock)) {
|
||||||
++affected;
|
++affected;
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren