Setting MaxStackQuantity

I was searching through the javadocs and didn’t see an obvious way to do this, but is it possible to set the maximum quantity of an itemstack? The documentation of ItemStack#getMaxStackQuantity seems to imply that this is possible.


Good catch! Unfortunately, it’s not possible to set the max stack quantity sanely in the game. Since there’s been increasingly more validation from the base game on various numbers (including quantity and damage value), setting the max quantity possible on an ItemStack was simply not feasible. Updating the javadocs is the best solution at the current time. @Zidane or @Deamon, if one of you could add this to the OCD list for the API, that’d be great.

1 Like

Good to know! Thanks gabizou!