Package net.minecraft.loot.function
Record Class SetAttributesLootFunction.Attribute
java.lang.Object
java.lang.Record
net.minecraft.loot.function.SetAttributesLootFunction.Attribute
- Record Components:
name
-attribute
-operation
-amount
-slots
-id
-
- Enclosing class:
SetAttributesLootFunction
private static record SetAttributesLootFunction.Attribute(String name, RegistryEntry<EntityAttribute> attribute, EntityAttributeModifier.Operation operation, LootNumberProvider amount, List<AttributeModifierSlot> slots, Optional<UUID> id)
extends Record
- Mappings:
Namespace Name named net/minecraft/loot/function/SetAttributesLootFunction$Attribute
intermediary net/minecraft/class_137$class_138
official esc$b
named name
intermediary comp_1859
official b
named attribute
intermediary comp_1860
official c
named operation
intermediary comp_1861
official d
named amount
intermediary comp_1862
official e
named slots
intermediary comp_1863
official f
named id
intermediary comp_1864
official g
-
Field Summary
Modifier and TypeFieldDescriptionprivate final LootNumberProvider
The field for theamount
record component.private final RegistryEntry
<EntityAttribute> The field for theattribute
record component.static final com.mojang.serialization.Codec
<SetAttributesLootFunction.Attribute> private static final com.mojang.serialization.Codec
<List<AttributeModifierSlot>> The field for theid
record component.private final String
The field for thename
record component.private final EntityAttributeModifier.Operation
The field for theoperation
record component.private final List
<AttributeModifierSlot> The field for theslots
record component. -
Constructor Summary
ConstructorDescriptionAttribute
(String name, RegistryEntry<EntityAttribute> registryEntry, EntityAttributeModifier.Operation operation, LootNumberProvider amount, List<AttributeModifierSlot> list, Optional<UUID> optional) -
Method Summary
Modifier and TypeMethodDescriptionamount()
Returns the value of theamount
record component.Returns the value of theattribute
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.id()
Returns the value of theid
record component.name()
Returns the value of thename
record component.Returns the value of theoperation
record component.slots()
Returns the value of theslots
record component.final String
toString()
Returns a string representation of this record class.
-
Field Details
-
name
The field for thename
record component. -
attribute
The field for theattribute
record component. -
operation
The field for theoperation
record component. -
amount
The field for theamount
record component. -
slots
The field for theslots
record component. -
id
The field for theid
record component. -
EQUIPMENT_SLOT_LIST_CODEC
private static final com.mojang.serialization.Codec<List<AttributeModifierSlot>> EQUIPMENT_SLOT_LIST_CODEC- Mappings:
Namespace Name Mixin selector named EQUIPMENT_SLOT_LIST_CODEC
Lnet/minecraft/loot/function/SetAttributesLootFunction$Attribute;EQUIPMENT_SLOT_LIST_CODEC:Lcom/mojang/serialization/Codec;
intermediary field_45838
Lnet/minecraft/class_137$class_138;field_45838:Lcom/mojang/serialization/Codec;
official h
Lesc$b;h:Lcom/mojang/serialization/Codec;
-
CODEC
- Mappings:
Namespace Name Mixin selector named CODEC
Lnet/minecraft/loot/function/SetAttributesLootFunction$Attribute;CODEC:Lcom/mojang/serialization/Codec;
intermediary field_45837
Lnet/minecraft/class_137$class_138;field_45837:Lcom/mojang/serialization/Codec;
official a
Lesc$b;a:Lcom/mojang/serialization/Codec;
-
-
Constructor Details
-
Attribute
Attribute(String name, RegistryEntry<EntityAttribute> registryEntry, EntityAttributeModifier.Operation operation, LootNumberProvider amount, List<AttributeModifierSlot> list, Optional<UUID> optional) - Mappings:
Namespace Name Mixin selector named <init>
Lnet/minecraft/loot/function/SetAttributesLootFunction$Attribute;<init>(Ljava/lang/String;Lnet/minecraft/registry/entry/RegistryEntry;Lnet/minecraft/entity/attribute/EntityAttributeModifier$Operation;Lnet/minecraft/loot/provider/number/LootNumberProvider;Ljava/util/List;Ljava/util/Optional;)V
intermediary <init>
Lnet/minecraft/class_137$class_138;<init>(Ljava/lang/String;Lnet/minecraft/class_6880;Lnet/minecraft/class_1322$class_1323;Lnet/minecraft/class_5658;Ljava/util/List;Ljava/util/Optional;)V
official <init>
Lesc$b;<init>(Ljava/lang/String;Lji;Lbuw$a;Leuo;Ljava/util/List;Ljava/util/Optional;)V
-
-
Method Details
-
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)
. -
name
Returns the value of thename
record component.- Returns:
- the value of the
name
record component
-
attribute
Returns the value of theattribute
record component.- Returns:
- the value of the
attribute
record component
-
operation
Returns the value of theoperation
record component.- Returns:
- the value of the
operation
record component
-
amount
Returns the value of theamount
record component.- Returns:
- the value of the
amount
record component
-
slots
Returns the value of theslots
record component.- Returns:
- the value of the
slots
record component
-
id
Returns the value of theid
record component.- Returns:
- the value of the
id
record component
-