Add NBT serialization from SirCmpwn's fork