getMaxStackSize() for itemstack, player, and world objects

Issue #9 resolved
Flamarow created an issue

This function would be just how it sounds. It will output the max stack size for the item can be. That way you can have conditions like this:

if(itemstack.getMaxStackSize() < itemstack.getStackSize()) { //do something }

Main use for me would be to test if there is any room left in the player's inventory for a specific item, but I am sure this function could have other uses as well.

Comments (1)

  1. cubex2 repo owner

    Added player.getItemMaxStackSize(), itemstack.getMaxStackSize() and world.getContainerSlotMaxStackSize().

  2. Log in to comment