Package net.minecraft.loot.functions
Class SetContents
- java.lang.Object
-
- net.minecraft.loot.LootFunction
-
- net.minecraft.loot.functions.SetContents
-
- All Implemented Interfaces:
java.util.function.BiFunction<ItemStack,LootContext,ItemStack>,ILootFunction,IParameterized
public class SetContents extends LootFunction
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classSetContents.Builderstatic classSetContents.Serializer-
Nested classes/interfaces inherited from interface net.minecraft.loot.functions.ILootFunction
ILootFunction.IBuilder
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.List<LootEntry>entries-
Fields inherited from class net.minecraft.loot.LootFunction
predicates
-
-
Constructor Summary
Constructors Modifier Constructor Description privateSetContents(ILootCondition[] p_i51226_1_, java.util.List<LootEntry> p_i51226_2_)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description LootFunctionTypegetType()ItemStackrun(ItemStack p_215859_1_, LootContext p_215859_2_)static SetContents.BuildersetContents()voidvalidate(ValidationTracker p_225580_1_)-
Methods inherited from class net.minecraft.loot.LootFunction
apply, simpleBuilder
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.minecraft.loot.IParameterized
getReferencedContextParams
-
-
-
-
Field Detail
-
entries
private final java.util.List<LootEntry> entries
-
-
Constructor Detail
-
SetContents
private SetContents(ILootCondition[] p_i51226_1_, java.util.List<LootEntry> p_i51226_2_)
-
-
Method Detail
-
getType
public LootFunctionType getType()
-
run
public ItemStack run(ItemStack p_215859_1_, LootContext p_215859_2_)
- Specified by:
runin classLootFunction
-
validate
public void validate(ValidationTracker p_225580_1_)
- Specified by:
validatein interfaceIParameterized- Overrides:
validatein classLootFunction
-
setContents
public static SetContents.Builder setContents()
-
-