TestBlockPaste-Without-Water #146
@ -142,21 +142,21 @@ public class FlatteningWrapper15 implements FlatteningWrapper {
|
|||||||
if (pasteOptions.getColor() != Color.YELLOW) {
|
if (pasteOptions.getColor() != Color.YELLOW) {
|
||||||
changeColor(clipboard, pasteOptions.getColor());
|
changeColor(clipboard, pasteOptions.getColor());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Set<String> blocks = new HashSet<>();
|
||||||
|
if (pasteOptions.isOnlyColors()) {
|
||||||
|
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_wool");
|
||||||
|
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_terracotta");
|
||||||
zOnlyKroks markierte diese Unterhaltung als gelöst
Veraltet
|
|||||||
|
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_glazed_terracotta");
|
||||||
|
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_stained_glass");
|
||||||
|
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_stained_glass_pane");
|
||||||
|
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_concrete");
|
||||||
|
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_concrete_powder");
|
||||||
|
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_carpet");
|
||||||
|
}
|
||||||
e.setMask(new Mask() {
|
e.setMask(new Mask() {
|
||||||
@Override
|
@Override
|
||||||
public boolean test(BlockVector3 blockVector3) {
|
public boolean test(BlockVector3 blockVector3) {
|
||||||
Set<String> blocks = new HashSet<>();
|
|
||||||
if (pasteOptions.isOnlyColors()) {
|
|
||||||
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_wool");
|
|
||||||
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_terracotta");
|
|
||||||
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_glazed_terracotta");
|
|
||||||
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_stained_glass");
|
|
||||||
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_stained_glass_pane");
|
|
||||||
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_concrete");
|
|
||||||
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_concrete_powder");
|
|
||||||
blocks.add("minecraft:" + pasteOptions.getColor().name().toLowerCase() + "_carpet");
|
|
||||||
}
|
|
||||||
|
|
||||||
BaseBlock block = clipboard.getFullBlock(blockVector3);
|
BaseBlock block = clipboard.getFullBlock(blockVector3);
|
||||||
String blockName = block.toString().toLowerCase();
|
String blockName = block.toString().toLowerCase();
|
||||||
return !blockName.equals("minecraft:water") || blocks.contains(blockName);
|
return !blockName.equals("minecraft:water") || blocks.contains(blockName);
|
||||||
zOnlyKroks markierte diese Unterhaltung als gelöst
Veraltet
Lixfel
hat
Waterlogged-Blöcke werden ebenso Probleme machen. Da könnte man auf ein contains waterlogged=true machen oder ggf. statt über Strings auch direkt über die WorldEdit-Materials/-Blocks, aber das wäre ein größerer Umbau. Waterlogged-Blöcke werden ebenso Probleme machen. Da könnte man auf ein contains waterlogged=true machen oder ggf. statt über Strings auch direkt über die WorldEdit-Materials/-Blocks, aber das wäre ein größerer Umbau.
|
|||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren
Warum schreibst das hier immer rein und machst es nicht optional anhand von dem color flag?