re-added missed changes from mesh serialization feature branch; fixed ios build