TerraFirmaCraft

TerraFirmaCraft

2M Downloads

small vessels cannot hold various items

agilmore2 opened this issue ยท 3 comments

commented

Small vessels cannot hold light/very small items anymore.
Seeds, feathers, food do not go in.
medium/normal things like nuggets work
light/small things like straw works
medium/very small things like thatch work.

Meta Info

  • TFC Version: build 92
commented

Sorry, I poorly fixed the last issue. Looks like what needs to be done here:


should be:

IItemSize cap = CapabilityItemSize.getIItemSize(stack)
if(cap != null)
{
    ...
}

@alcatrazEscapee

commented

Ah, so tfc seeds don't implement IItemSize either, assuming they'd get light/very small by default?

commented

TFC items generally implement IItemSize as an interface, as it's simpler.
TFC blocks implement the interface, but require ((ItemBlock) stack.getItem()) instanceof IItemSize to access the interface
Vanilla and other mod items add it as a capability, as we can't implement any interfaces on existing blocks or items.
Thus the reason we have a helper method to get the size from a stack instead of doing instanceof directly.