예제 #1
0
  @Override
  public IItemStack updateTag(IData tagUpdate) {
    if (tag == null) {
      if (stack.getTagCompound() == null) {
        return withTag(tagUpdate);
      }

      tag = NBTConverter.from(stack.getTagCompound(), true);
    }

    IData updated = tag.update(tagUpdate);
    return withTag(updated);
  }
예제 #2
0
 @Override
 public ILiquidStack withTag(IData data) {
   FluidStack result = new FluidStack(stack.fluidID, stack.amount);
   result.tag = (NBTTagCompound) NBTConverter.from(data);
   return new MCLiquidStack(result, data.immutable());
 }