protobuf functions now returns offsets instread pointers