The Meaning of Life, the Universe, and Everything.
If anyone can maybe take a look at this and see what I am royally screwing up I'd appreciate it, because I have been at it for hours. I just want to save my items in the ItemStack. Here is the relevant pieces of code:
As you can see I am attempting to implement forge's IItemHandlerCapability. I've pretty much got it working except for the fact that it will not save the items placed in the inventory. Once the inventory closes and you re-open it all the items are gone. Now I am well aware this is likely happening becasue I am either creating a new ItemHandler or not properly writing/reading the data to/in NBT. This is the first time I am working with a Forge Premade Capability, so I am appologize if it is a noob mistake. If anyone can provide some assistance I would greatly appreciate it.