Package net.minecraft.predicate.entity
Record Class DistancePredicate
java.lang.Object
java.lang.Record
net.minecraft.predicate.entity.DistancePredicate
- Record Components:
x-y-z-horizontal-absolute-
public record DistancePredicate(NumberRange.DoubleRange x, NumberRange.DoubleRange y, NumberRange.DoubleRange z, NumberRange.DoubleRange horizontal, NumberRange.DoubleRange absolute)
extends Record
- Mappings:
Namespace Name named net/minecraft/predicate/entity/DistancePredicateintermediary net/minecraft/class_2025official bmnamed xintermediary comp_1743official bnamed yintermediary comp_1744official cnamed zintermediary comp_1745official dnamed horizontalintermediary comp_1746official enamed absoluteintermediary comp_1747official f
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final NumberRange.DoubleRangeThe field for theabsoluterecord component.static final com.mojang.serialization.Codec<DistancePredicate> private final NumberRange.DoubleRangeThe field for thehorizontalrecord component.private final NumberRange.DoubleRangeThe field for thexrecord component.private final NumberRange.DoubleRangeThe field for theyrecord component.private final NumberRange.DoubleRangeThe field for thezrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionDistancePredicate(NumberRange.DoubleRange x, NumberRange.DoubleRange y, NumberRange.DoubleRange z, NumberRange.DoubleRange horizontal, NumberRange.DoubleRange absolute) Creates an instance of aDistancePredicaterecord class. -
Method Summary
Modifier and TypeMethodDescriptionabsolute()Returns the value of theabsoluterecord component.static DistancePredicateabsolute(NumberRange.DoubleRange absolute) final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of thehorizontalrecord component.static DistancePredicatehorizontal(NumberRange.DoubleRange horizontal) booleantest(double x0, double y0, double z0, double x1, double y1, double z1) final StringtoString()Returns a string representation of this record class.x()Returns the value of thexrecord component.y()Returns the value of theyrecord component.static DistancePredicatez()Returns the value of thezrecord component.
-
Field Details
-
x
The field for thexrecord component. -
y
The field for theyrecord component. -
z
The field for thezrecord component. -
horizontal
The field for thehorizontalrecord component. -
absolute
The field for theabsoluterecord component. -
CODEC
- Mappings:
Namespace Name Mixin selector named CODECLnet/minecraft/predicate/entity/DistancePredicate;CODEC:Lcom/mojang/serialization/Codec;intermediary field_45728Lnet/minecraft/class_2025;field_45728:Lcom/mojang/serialization/Codec;official aLbm;a:Lcom/mojang/serialization/Codec;
-
-
Constructor Details
-
DistancePredicate
public DistancePredicate(NumberRange.DoubleRange x, NumberRange.DoubleRange y, NumberRange.DoubleRange z, NumberRange.DoubleRange horizontal, NumberRange.DoubleRange absolute) Creates an instance of aDistancePredicaterecord class.- Parameters:
x- the value for thexrecord componenty- the value for theyrecord componentz- the value for thezrecord componenthorizontal- the value for thehorizontalrecord componentabsolute- the value for theabsoluterecord component
-
-
Method Details
-
horizontal
- Mappings:
Namespace Name Mixin selector named horizontalLnet/minecraft/predicate/entity/DistancePredicate;horizontal(Lnet/minecraft/predicate/NumberRange$DoubleRange;)Lnet/minecraft/predicate/entity/DistancePredicate;intermediary method_8860Lnet/minecraft/class_2025;method_8860(Lnet/minecraft/class_2096$class_2099;)Lnet/minecraft/class_2025;official aLbm;a(Ldh$c;)Lbm;
-
y
- Mappings:
Namespace Name Mixin selector named yLnet/minecraft/predicate/entity/DistancePredicate;y(Lnet/minecraft/predicate/NumberRange$DoubleRange;)Lnet/minecraft/predicate/entity/DistancePredicate;intermediary method_8856Lnet/minecraft/class_2025;method_8856(Lnet/minecraft/class_2096$class_2099;)Lnet/minecraft/class_2025;official bLbm;b(Ldh$c;)Lbm;
-
absolute
- Mappings:
Namespace Name Mixin selector named absoluteLnet/minecraft/predicate/entity/DistancePredicate;absolute(Lnet/minecraft/predicate/NumberRange$DoubleRange;)Lnet/minecraft/predicate/entity/DistancePredicate;intermediary method_37223Lnet/minecraft/class_2025;method_37223(Lnet/minecraft/class_2096$class_2099;)Lnet/minecraft/class_2025;official cLbm;c(Ldh$c;)Lbm;
-
test
public boolean test(double x0, double y0, double z0, double x1, double y1, double z1) - Mappings:
Namespace Name Mixin selector named testLnet/minecraft/predicate/entity/DistancePredicate;test(DDDDDD)Zintermediary method_8859Lnet/minecraft/class_2025;method_8859(DDDDDD)Zofficial aLbm;a(DDDDDD)Z
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
x
Returns the value of thexrecord component.- Returns:
- the value of the
xrecord component
-
y
Returns the value of theyrecord component.- Returns:
- the value of the
yrecord component
-
z
Returns the value of thezrecord component.- Returns:
- the value of the
zrecord component
-
horizontal
Returns the value of thehorizontalrecord component.- Returns:
- the value of the
horizontalrecord component
-
absolute
Returns the value of theabsoluterecord component.- Returns:
- the value of the
absoluterecord component
-