Class SetItemCountFunction
java.lang.Object
net.minecraft.world.level.storage.loot.functions.LootItemConditionalFunction
net.minecraft.world.level.storage.loot.functions.SetItemCountFunction
- All Implemented Interfaces:
BiFunction<ItemStack,
,LootContext, ItemStack> LootItemFunction
,LootContextUser
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.world.level.storage.loot.functions.LootItemConditionalFunction
LootItemConditionalFunction.Builder<T extends LootItemConditionalFunction.Builder<T>>, LootItemConditionalFunction.DummyBuilder
-
Field Summary
Modifier and TypeFieldDescriptionprivate final boolean
static final com.mojang.serialization.Codec<SetItemCountFunction>
private final NumberProvider
Fields inherited from class net.minecraft.world.level.storage.loot.functions.LootItemConditionalFunction
predicates
-
Constructor Summary
ModifierConstructorDescriptionprivate
SetItemCountFunction
(List<LootItemCondition> p_298181_, NumberProvider p_165410_, boolean p_165411_) -
Method Summary
Modifier and TypeMethodDescriptionSet<LootContextParam<?>>
getType()
run
(ItemStack p_81006_, LootContext p_81007_) static LootItemConditionalFunction.Builder<?>
setCount
(NumberProvider p_165413_) static LootItemConditionalFunction.Builder<?>
setCount
(NumberProvider p_165415_, boolean p_165416_) Methods inherited from class net.minecraft.world.level.storage.loot.functions.LootItemConditionalFunction
apply, commonFields, simpleBuilder, validate
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.util.function.BiFunction
andThen
-
Field Details
-
CODEC
-
value
-
add
private final boolean add
-
-
Constructor Details
-
SetItemCountFunction
private SetItemCountFunction(List<LootItemCondition> p_298181_, NumberProvider p_165410_, boolean p_165411_)
-
-
Method Details
-
getType
-
getReferencedContextParams
-
run
- Specified by:
run
in classLootItemConditionalFunction
-
setCount
-
setCount
public static LootItemConditionalFunction.Builder<?> setCount(NumberProvider p_165415_, boolean p_165416_)
-