DistancePredicate

Importing the class

It might be required for you to import the package if you encounter any issues (like casting an Array), so better be safe than sorry and add the import at the very top of the file.

script.zs
import crafttweaker.api.predicate.DistancePredicate;

Static Methods

Return Type: DistancePredicate

script.zs
DistancePredicate.absoluteDistance(bounds as DoubleMinMaxBoundsPredicate) as DistancePredicate
ParameterType
Parameter
bounds
Type
DoubleMinMaxBoundsPredicate

Return Type: DistancePredicate

script.zs
// DistancePredicate.any() as DistancePredicate
DistancePredicate.any();

Return Type: DistancePredicate

script.zs
DistancePredicate.create(x as DoubleMinMaxBoundsPredicate, y as DoubleMinMaxBoundsPredicate, z as DoubleMinMaxBoundsPredicate, horizontal as DoubleMinMaxBoundsPredicate, absolute as DoubleMinMaxBoundsPredicate) as DistancePredicate
ParameterType
Parameter
x
Type
DoubleMinMaxBoundsPredicate
Parameter
y
Type
DoubleMinMaxBoundsPredicate
Parameter
z
Type
DoubleMinMaxBoundsPredicate
Parameter
horizontal
Type
DoubleMinMaxBoundsPredicate
Parameter
absolute
Type
DoubleMinMaxBoundsPredicate

Return Type: DistancePredicate

script.zs
DistancePredicate.horizontalDistance(bounds as DoubleMinMaxBoundsPredicate) as DistancePredicate
ParameterType
Parameter
bounds
Type
DoubleMinMaxBoundsPredicate

Return Type: DistancePredicate

script.zs
DistancePredicate.verticalDistance(bounds as DoubleMinMaxBoundsPredicate) as DistancePredicate
ParameterType
Parameter
bounds
Type
DoubleMinMaxBoundsPredicate

Return Type: DistancePredicate

script.zs
DistancePredicate.xyz(x as DoubleMinMaxBoundsPredicate, y as DoubleMinMaxBoundsPredicate, z as DoubleMinMaxBoundsPredicate) as DistancePredicate
ParameterType
Parameter
x
Type
DoubleMinMaxBoundsPredicate
Parameter
y
Type
DoubleMinMaxBoundsPredicate
Parameter
z
Type
DoubleMinMaxBoundsPredicate