类 ContainerHelper
java.lang.Object
net.minecraft.world.ContainerHelper
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static int
clearOrCountMatchingItems
(Container pContainer, Predicate<ItemStack> pItemPredicate, int pMaxItems, boolean pSimulate) static int
clearOrCountMatchingItems
(ItemStack pStack, Predicate<ItemStack> pItemPredicate, int pMaxItems, boolean pSimulate) static void
loadAllItems
(CompoundTag pTag, NonNullList<ItemStack> pList) static ItemStack
removeItem
(List<ItemStack> pStacks, int pIndex, int pAmount) static CompoundTag
saveAllItems
(CompoundTag pTag, NonNullList<ItemStack> pList) static CompoundTag
saveAllItems
(CompoundTag pTag, NonNullList<ItemStack> pList, boolean pSaveEmpty) static ItemStack
-
构造器详细资料
-
ContainerHelper
public ContainerHelper()
-
-
方法详细资料
-
removeItem
-
takeItem
-
saveAllItems
-
saveAllItems
public static CompoundTag saveAllItems(CompoundTag pTag, NonNullList<ItemStack> pList, boolean pSaveEmpty) -
loadAllItems
-
clearOrCountMatchingItems
-
clearOrCountMatchingItems
-