Class LootItem
java.lang.Object
net.minecraft.world.level.storage.loot.entries.LootPoolEntryContainer
net.minecraft.world.level.storage.loot.entries.LootPoolSingletonContainer
net.minecraft.world.level.storage.loot.entries.LootItem
- All Implemented Interfaces:
ComposableEntryContainer, Validatable
-
Nested Class Summary
Nested classes/interfaces inherited from class LootPoolSingletonContainer
LootPoolSingletonContainer.Builder<T>, LootPoolSingletonContainer.EntryBase, LootPoolSingletonContainer.EntryConstructor -
Field Summary
FieldsModifier and TypeFieldDescriptionFields inherited from class LootPoolSingletonContainer
DEFAULT_QUALITY, DEFAULT_WEIGHT, functions, quality, weightFields inherited from class LootPoolEntryContainer
conditionsFields inherited from interface ComposableEntryContainer
ALWAYS_FALSE, ALWAYS_TRUE -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateLootItem(Holder<Item> item, int weight, int quality, List<LootItemCondition> conditions, List<LootItemFunction> functions) -
Method Summary
Modifier and TypeMethodDescriptioncodec()voidcreateItemStack(Consumer<ItemStack> output, LootContext context) static LootPoolSingletonContainer.Builder<?> lootTableItem(ItemLike item) Methods inherited from class LootPoolSingletonContainer
expand, simpleBuilder, singletonFields, validateMethods inherited from class LootPoolEntryContainer
canRun, commonFieldsMethods 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
-
item
-
-
Constructor Details
-
LootItem
private LootItem(Holder<Item> item, int weight, int quality, List<LootItemCondition> conditions, List<LootItemFunction> functions)
-
-
Method Details
-
codec
- Specified by:
codecin classLootPoolSingletonContainer
-
createItemStack
- Specified by:
createItemStackin classLootPoolSingletonContainer
-
lootTableItem
-