Class PlayerInventory

    • Constructor Detail

      • PlayerInventory

        public PlayerInventory​(PlayerEntity p_i1750_1_)
    • Method Detail

      • getSelected

        public ItemStack getSelected()
      • getSelectionSize

        public static int getSelectionSize()
      • hasRemainingSpaceForItem

        private boolean hasRemainingSpaceForItem​(ItemStack p_184436_1_,
                                                 ItemStack p_184436_2_)
      • isSameItem

        private boolean isSameItem​(ItemStack p_184431_1_,
                                   ItemStack p_184431_2_)
      • getFreeSlot

        public int getFreeSlot()
      • setPickedItem

        public void setPickedItem​(ItemStack p_184434_1_)
      • pickSlot

        public void pickSlot​(int p_184430_1_)
      • isHotbarSlot

        public static boolean isHotbarSlot​(int p_184435_0_)
      • findSlotMatchingItem

        public int findSlotMatchingItem​(ItemStack p_184429_1_)
      • findSlotMatchingUnusedItem

        public int findSlotMatchingUnusedItem​(ItemStack p_194014_1_)
      • getSuitableHotbarSlot

        public int getSuitableHotbarSlot()
      • swapPaint

        public void swapPaint​(double p_195409_1_)
      • clearOrCountMatchingItems

        public int clearOrCountMatchingItems​(java.util.function.Predicate<ItemStack> p_234564_1_,
                                             int p_234564_2_,
                                             IInventory p_234564_3_)
      • addResource

        private int addResource​(ItemStack p_70452_1_)
      • addResource

        private int addResource​(int p_191973_1_,
                                ItemStack p_191973_2_)
      • getSlotWithRemainingSpace

        public int getSlotWithRemainingSpace​(ItemStack p_70432_1_)
      • tick

        public void tick()
      • add

        public boolean add​(ItemStack p_70441_1_)
      • add

        public boolean add​(int p_191971_1_,
                           ItemStack p_191971_2_)
      • placeItemBackInInventory

        public void placeItemBackInInventory​(World p_191975_1_,
                                             ItemStack p_191975_2_)
      • removeItem

        public void removeItem​(ItemStack p_184437_1_)
      • getDestroySpeed

        public float getDestroySpeed​(BlockState p_184438_1_)
      • load

        public void load​(ListNBT p_70443_1_)
      • getArmor

        public ItemStack getArmor​(int p_70440_1_)
      • hurtArmor

        public void hurtArmor​(DamageSource p_234563_1_,
                              float p_234563_2_)
      • dropAll

        public void dropAll()
      • getTimesChanged

        public int getTimesChanged()
      • setCarried

        public void setCarried​(ItemStack p_70437_1_)
      • contains

        public boolean contains​(ItemStack p_70431_1_)
      • contains

        public boolean contains​(ITag<Item> p_199712_1_)
      • fillStackedContents

        public void fillStackedContents​(RecipeItemHelper p_201571_1_)