Package net.minecraft.predicate.entity
Record Class InputPredicate
java.lang.Object
java.lang.Record
net.minecraft.predicate.entity.InputPredicate
- Record Components:
- forward-
- backward-
- left-
- right-
- jump-
- sneak-
- sprint-
public record InputPredicate(Optional<Boolean> forward, Optional<Boolean> backward, Optional<Boolean> left, Optional<Boolean> right, Optional<Boolean> jump, Optional<Boolean> sneak, Optional<Boolean> sprint)
extends Record
- Mappings:
- Namespace - Name - named - net/minecraft/predicate/entity/InputPredicate- intermediary - net/minecraft/class_10184- official - ci- named - forward- intermediary - comp_3152- official - b- named - backward- intermediary - comp_3153- official - c- named - left- intermediary - comp_3154- official - d- named - right- intermediary - comp_3155- official - e- named - jump- intermediary - comp_3156- official - f- named - sneak- intermediary - comp_3157- official - g- named - sprint- intermediary - comp_3158- official - h
- 
Field SummaryFieldsModifier and TypeFieldDescriptionThe field for thebackwardrecord component.static final com.mojang.serialization.Codec<InputPredicate> The field for theforwardrecord component.The field for thejumprecord component.The field for theleftrecord component.The field for therightrecord component.The field for thesneakrecord component.The field for thesprintrecord component.
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionbackward()Returns the value of thebackwardrecord component.final booleanIndicates whether some other object is "equal to" this one.forward()Returns the value of theforwardrecord component.final inthashCode()Returns a hash code value for this object.jump()Returns the value of thejumprecord component.private booleankeyMatches(Optional<Boolean> keyPressed, boolean inputPressed) left()Returns the value of theleftrecord component.booleanmatches(PlayerInput playerInput) right()Returns the value of therightrecord component.sneak()Returns the value of thesneakrecord component.sprint()Returns the value of thesprintrecord component.final StringtoString()Returns a string representation of this record class.
- 
Field Details- 
forwardThe field for theforwardrecord component.
- 
backwardThe field for thebackwardrecord component.
- 
leftThe field for theleftrecord component.
- 
rightThe field for therightrecord component.
- 
jumpThe field for thejumprecord component.
- 
sneakThe field for thesneakrecord component.
- 
sprintThe field for thesprintrecord component.
- 
CODEC- Mappings:
- Namespace - Name - Mixin selector - named - CODEC- Lnet/minecraft/predicate/entity/InputPredicate;CODEC:Lcom/mojang/serialization/Codec;- intermediary - field_54096- Lnet/minecraft/class_10184;field_54096:Lcom/mojang/serialization/Codec;- official - a- Lci;a:Lcom/mojang/serialization/Codec;
 
 
- 
- 
Constructor Details- 
InputPredicate
 
- 
- 
Method Details- 
matches- Mappings:
- Namespace - Name - Mixin selector - named - matches- Lnet/minecraft/predicate/entity/InputPredicate;matches(Lnet/minecraft/util/PlayerInput;)Z- intermediary - method_63643- Lnet/minecraft/class_10184;method_63643(Lnet/minecraft/class_10185;)Z- official - a- Lci;a(Lcow;)Z
 
- 
keyMatches- Mappings:
- Namespace - Name - Mixin selector - named - keyMatches- Lnet/minecraft/predicate/entity/InputPredicate;keyMatches(Ljava/util/Optional;Z)Z- intermediary - method_63645- Lnet/minecraft/class_10184;method_63645(Ljava/util/Optional;Z)Z- official - a- Lci;a(Ljava/util/Optional;Z)Z
 
- 
toStringReturns 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.
- 
hashCodepublic 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.
- 
equalsIndicates 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).
- 
forwardReturns the value of theforwardrecord component.- Returns:
- the value of the forwardrecord component
 
- 
backwardReturns the value of thebackwardrecord component.- Returns:
- the value of the backwardrecord component
 
- 
leftReturns the value of theleftrecord component.- Returns:
- the value of the leftrecord component
 
- 
rightReturns the value of therightrecord component.- Returns:
- the value of the rightrecord component
 
- 
jumpReturns the value of thejumprecord component.- Returns:
- the value of the jumprecord component
 
- 
sneakReturns the value of thesneakrecord component.- Returns:
- the value of the sneakrecord component
 
- 
sprintReturns the value of thesprintrecord component.- Returns:
- the value of the sprintrecord component
 
 
-