Package net.minecraft.predicate.entity
Record Class LightningBoltPredicate
java.lang.Object
java.lang.Record
net.minecraft.predicate.entity.LightningBoltPredicate
- Record Components:
blocksSetOnFire-entityStruck-
- All Implemented Interfaces:
TypeSpecificPredicate
public record LightningBoltPredicate(NumberRange.IntRange blocksSetOnFire, Optional<EntityPredicate> entityStruck)
extends Record
implements TypeSpecificPredicate
- Mappings:
Namespace Name official cgintermediary net/minecraft/class_6404named net/minecraft/predicate/entity/LightningBoltPredicateofficial cintermediary comp_1792named blocksSetOnFireofficial dintermediary comp_1793named entityStruck
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.minecraft.predicate.entity.TypeSpecificPredicate
TypeSpecificPredicate.Deserializers, TypeSpecificPredicate.Type -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final NumberRange.IntRangeThe field for theblocksSetOnFirerecord component.static final com.mojang.serialization.MapCodec<LightningBoltPredicate>private final Optional<EntityPredicate>The field for theentityStruckrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionLightningBoltPredicate(NumberRange.IntRange blocksSetOnFire, Optional<EntityPredicate> optional) -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theblocksSetOnFirerecord component.Returns the value of theentityStruckrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.static LightningBoltPredicateof(NumberRange.IntRange blocksSetOnFire) booleantest(Entity entity, ServerWorld world, @Nullable Vec3d pos) final StringtoString()Returns a string representation of this record class.type()
-
Field Details
-
blocksSetOnFire
The field for theblocksSetOnFirerecord component. -
entityStruck
The field for theentityStruckrecord component. -
CODEC
- Mappings:
Namespace Name Mixin selector official bLcg;b:Lcom/mojang/serialization/MapCodec;intermediary field_45759Lnet/minecraft/class_6404;field_45759:Lcom/mojang/serialization/MapCodec;named CODECLnet/minecraft/predicate/entity/LightningBoltPredicate;CODEC:Lcom/mojang/serialization/MapCodec;
-
-
Constructor Details
-
LightningBoltPredicate
public LightningBoltPredicate(NumberRange.IntRange blocksSetOnFire, Optional<EntityPredicate> optional) - Mappings:
Namespace Name Mixin selector official <init>Lcg;<init>(Lck$d;Ljava/util/Optional;)Vintermediary <init>Lnet/minecraft/class_6404;<init>(Lnet/minecraft/class_2096$class_2100;Ljava/util/Optional;)Vnamed <init>Lnet/minecraft/predicate/entity/LightningBoltPredicate;<init>(Lnet/minecraft/predicate/NumberRange$IntRange;Ljava/util/Optional;)V
-
-
Method Details
-
of
- Mappings:
Namespace Name Mixin selector official aLcg;a(Lck$d;)Lcg;intermediary method_37237Lnet/minecraft/class_6404;method_37237(Lnet/minecraft/class_2096$class_2100;)Lnet/minecraft/class_6404;named ofLnet/minecraft/predicate/entity/LightningBoltPredicate;of(Lnet/minecraft/predicate/NumberRange$IntRange;)Lnet/minecraft/predicate/entity/LightningBoltPredicate;
-
type
- Specified by:
typein interfaceTypeSpecificPredicate- Mappings:
Namespace Name Mixin selector official aLbq;a()Lbq$a;intermediary comp_1776Lnet/minecraft/class_7376;comp_1776()Lnet/minecraft/class_7376$class_8745;named typeLnet/minecraft/predicate/entity/TypeSpecificPredicate;type()Lnet/minecraft/predicate/entity/TypeSpecificPredicate$Type;
-
test
- Specified by:
testin interfaceTypeSpecificPredicate- Mappings:
Namespace Name Mixin selector official aLbq;a(Lblv;Land;Lelt;)Zintermediary method_22497Lnet/minecraft/class_7376;method_22497(Lnet/minecraft/class_1297;Lnet/minecraft/class_3218;Lnet/minecraft/class_243;)Znamed testLnet/minecraft/predicate/entity/TypeSpecificPredicate;test(Lnet/minecraft/entity/Entity;Lnet/minecraft/server/world/ServerWorld;Lnet/minecraft/util/math/Vec3d;)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). -
blocksSetOnFire
Returns the value of theblocksSetOnFirerecord component.- Returns:
- the value of the
blocksSetOnFirerecord component
-
entityStruck
Returns the value of theentityStruckrecord component.- Returns:
- the value of the
entityStruckrecord component
-