Skip to content

Commit 9f50ef1

Browse files
committed
Added comment explaining collider mesh null assignment
1 parent 2e1decd commit 9f50ef1

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

Assets/HoloToolkit/SpatialUnderstanding/Scripts/SpatialUnderstandingCustomMesh.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,7 @@ public void Commit()
123123
MeshObject.SetTriangles(tris, 0);
124124
MeshObject.RecalculateNormals();
125125
MeshObject.RecalculateBounds();
126+
// The null assignment is required by Unity in order to pick up the new mesh
126127
SpatialCollider.sharedMesh = null;
127128
SpatialCollider.sharedMesh = MeshObject;
128129
}

0 commit comments

Comments
 (0)