Update Upstream

f414af5 Fix the offset mask forcing negation of itself (1656)
Dieser Commit ist enthalten in:
NotMyFault 2021-07-26 00:48:38 +02:00
Ursprung aae5d037db
Commit 92b4524dd6
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 158F5701A6AAD00C
2 geänderte Dateien mit 4 neuen und 8 gelöschten Zeilen

Datei anzeigen

@ -6,8 +6,6 @@ import com.sk89q.worldedit.command.util.SuggestionHelper;
import com.sk89q.worldedit.extension.input.InputParseException;
import com.sk89q.worldedit.extension.input.ParserContext;
import com.sk89q.worldedit.function.mask.Mask;
import com.sk89q.worldedit.function.mask.MaskIntersection;
import com.sk89q.worldedit.function.mask.Masks;
import com.sk89q.worldedit.function.mask.OffsetMask;
import com.sk89q.worldedit.math.BlockVector3;
@ -45,8 +43,7 @@ public class RichOffsetMaskParser extends RichParser<Mask> {
int y = Integer.parseInt(arguments[1]);
int z = Integer.parseInt(arguments[2]);
Mask submask = worldEdit.getMaskFactory().parseFromInput(arguments[3], context);
OffsetMask offsetMask = new OffsetMask(submask, BlockVector3.at(x, y, z));
return new MaskIntersection(offsetMask, Masks.negate(submask));
return new OffsetMask(submask, BlockVector3.at(x, y, z));
}
}

Datei anzeigen

@ -24,8 +24,6 @@ import com.sk89q.worldedit.extension.input.InputParseException;
import com.sk89q.worldedit.extension.input.ParserContext;
import com.sk89q.worldedit.function.mask.ExistingBlockMask;
import com.sk89q.worldedit.function.mask.Mask;
import com.sk89q.worldedit.function.mask.MaskIntersection;
import com.sk89q.worldedit.function.mask.Masks;
import com.sk89q.worldedit.function.mask.OffsetMask;
import com.sk89q.worldedit.internal.registry.InputParser;
import com.sk89q.worldedit.math.BlockVector3;
@ -63,8 +61,9 @@ public class OffsetMaskParser extends InputParser<Mask> {
} else {
submask = new ExistingBlockMask(context.requireExtent());
}
OffsetMask offsetMask = new OffsetMask(submask, BlockVector3.at(0, firstChar == '>' ? -1 : 1, 0));
return new MaskIntersection(offsetMask, Masks.negate(submask));
//FAWE start - OffsetMask > OffsetsMask
return new OffsetMask(submask, BlockVector3.at(0, firstChar == '>' ? -1 : 1, 0));
//FAWE end
}
}