public void Clear() { this.mesh = null; this.vertexCount = 0; this.subMeshIndex = 0; for (int i = this.triangles.Count - 1; i >= 0; i--) { P3D_Triangle.Despawn(this.triangles[i]); } this.triangles.Clear(); for (int j = this.nodes.Count - 1; j >= 0; j--) { P3D_Node.Despawn(this.nodes[j]); } this.nodes.Clear(); }
// This allows you to reset this class public void Clear() { mesh = null; vertexCount = 0; materialIndex = 0; for (var i = triangles.Count - 1; i >= 0; i--) { P3D_Triangle.Despawn(triangles[i]); } triangles.Clear(); for (var i = nodes.Count - 1; i >= 0; i--) { P3D_Node.Despawn(nodes[i]); } nodes.Clear(); }