mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-12-22 17:27:38 +00:00
Use SingleBlockTypeMask for fixLiquid
This commit is contained in:
parent
2670e66ce2
commit
d7b3db215e
@ -1595,13 +1595,13 @@ public class EditSession extends PassthroughExtent implements AutoCloseable {
|
|||||||
checkArgument(radius >= 0, "radius >= 0 required");
|
checkArgument(radius >= 0, "radius >= 0 required");
|
||||||
|
|
||||||
// Our origins can only be liquids
|
// Our origins can only be liquids
|
||||||
Mask liquidMask = new BlockTypeMask(this, fluid);
|
Mask liquidMask = new SingleBlockTypeMask(this, fluid);
|
||||||
|
|
||||||
// But we will also visit air blocks
|
// But we will also visit air blocks
|
||||||
MaskIntersection blockMask = new MaskUnion(liquidMask, Masks.negate(new ExistingBlockMask(this)));
|
MaskIntersection blockMask = new MaskUnion(liquidMask, Masks.negate(new ExistingBlockMask(this)));
|
||||||
|
|
||||||
// There are boundaries that the routine needs to stay in
|
// There are boundaries that the routine needs to stay in
|
||||||
MaskIntersection mask = new MaskIntersection(
|
Mask mask = new MaskIntersection(
|
||||||
new BoundedHeightMask(0, Math.min(origin.getBlockY(), getWorld().getMaxY())),
|
new BoundedHeightMask(0, Math.min(origin.getBlockY(), getWorld().getMaxY())),
|
||||||
new RegionMask(new EllipsoidRegion(null, origin, Vector3.at(radius, radius, radius))),
|
new RegionMask(new EllipsoidRegion(null, origin, Vector3.at(radius, radius, radius))),
|
||||||
blockMask
|
blockMask
|
||||||
|
Loading…
Reference in New Issue
Block a user