Class SlotLoot
java.lang.Object
net.minecraft.world.level.storage.loot.entries.LootPoolEntryContainer
net.minecraft.world.level.storage.loot.entries.UniformContainerBase
net.minecraft.world.level.storage.loot.entries.SingleEntryContainerBase
net.minecraft.world.level.storage.loot.entries.SlotLoot
- All Implemented Interfaces:
ComposableEntryContainer, Validatable
-
Nested Class Summary
Nested classes/interfaces inherited from class UniformContainerBase
UniformContainerBase.Builder<T>, UniformContainerBase.EntryBase, UniformContainerBase.EntryConstructor -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.MapCodec<SlotLoot> private final Holder<SlotSource> Fields inherited from class UniformContainerBase
DEFAULT_QUALITY, DEFAULT_WEIGHT, quality, weightFields inherited from class LootPoolEntryContainer
condition, modifierFields inherited from interface ComposableEntryContainer
ALWAYS_FALSE, ALWAYS_TRUE -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateSlotLoot(Holder<SlotSource> slotSource, int weight, int quality, Optional<Holder<LootItemCondition>> condition, Optional<Holder<LootItemFunction>> modifier) -
Method Summary
Modifier and TypeMethodDescriptioncom.mojang.serialization.MapCodec<SlotLoot> codec()voidcreateItemStack(Consumer<ItemStack> output, LootContext context) voidvalidate(ValidationContext context) Methods inherited from class SingleEntryContainerBase
expandRawMethods inherited from class UniformContainerBase
simpleBuilder, uniformFieldsMethods inherited from class LootPoolEntryContainer
commonFields, expandMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface ComposableEntryContainer
and, or
-
Field Details
-
MAP_CODEC
-
slotSource
-
-
Constructor Details
-
SlotLoot
private SlotLoot(Holder<SlotSource> slotSource, int weight, int quality, Optional<Holder<LootItemCondition>> condition, Optional<Holder<LootItemFunction>> modifier)
-
-
Method Details
-
codec
- Specified by:
codecin classSingleEntryContainerBase
-
createItemStack
- Specified by:
createItemStackin classSingleEntryContainerBase
-
validate
- Specified by:
validatein interfaceValidatable- Overrides:
validatein classUniformContainerBase
-