Interface Mask
- All Known Implementing Classes:
ABlockMask
,AbstractDelegateMask
,AbstractExtentMask
,AbstractMask
,AdjacentAnyMask
,AdjacentMask
,AirMask
,AngleMask
,BiomeMask
,BlockCategoryMask
,BlockMask
,BlockStateMask
,BlockTypeMask
,BoundedHeightMask
,CachedMask
,DataMask
,ExistingBlockMask
,ExpressionMask
,ExtremaMask
,IdMask
,ImageBrushMask
,InverseMask
,InverseSingleBlockStateMask
,InverseSingleBlockTypeMask
,LayerBrushMask
,LiquidMask
,MaskIntersection
,Masks.AlwaysFalse
,Masks.AlwaysTrue
,Masks.NegatedMask
,MaskUnion
,NoiseFilter
,OffsetMask
,PlaneMask
,RadiusMask
,RandomMask
,RegionMask
,ROCAngleMask
,SimplexMask
,SingleBlockStateMask
,SingleBlockTypeMask
,SolidBlockMask
,SplatterBrushMask
,StencilBrushMask
,SurfaceAngleMask
,SurfaceMask
,WallMakeMask
,WallMask
,XAxisMask
,YAxisMask
,ZAxisMask
public interface Mask
Tests whether a given vector meets a criteria.
-
Method Summary
Modifier and TypeMethodDescriptioncopy()
Returns a copy of the mask.default Mask
inverse()
default Mask
optimize()
default boolean
boolean
test
(BlockVector3 vector) Returns true if the criteria is met.default Filter
toFilter
(Consumer<FilterBlock> run) default <T extends Filter>
MaskFilter<T> toFilter
(T filter) default Mask2D
toMask2D()
Get the 2D version of this mask if one exists.default Mask
tryCombine
(Mask other) default Mask
Returns null if no optimization took place otherwise a new/same maskdefault Mask
-
Method Details
-
test
Returns true if the criteria is met.- Parameters:
vector
- the vector to test- Returns:
- true if the criteria is met
-
toMask2D
Get the 2D version of this mask if one exists.- Returns:
- a 2D mask version or
null
if this mask can't be 2D
-
tryOptimize
Returns null if no optimization took place otherwise a new/same mask- Returns:
-
toFilter
-
tryCombine
-
tryOr
-
optimize
-
inverse
-
toFilter
-
replacesAir
default boolean replacesAir() -
copy
Mask copy()Returns a copy of the mask. Usually for multi-threaded operation- Returns:
- a clone of the mask
-