public bool Equals(SceneSelection other)
 {
     if (ReferenceEquals(null, other))
     {
         return(false);
     }
     if (ReferenceEquals(this, other))
     {
         return(true);
     }
     return(Equals(gameObject, other.gameObject) &&
            Equals(mesh, other.mesh) &&
            vertex == other.vertex &&
            edge.Equals(other.edge) &&
            Equals(face, other.face));
 }
Beispiel #2
0
        internal static Face GetFace(this ProBuilderMesh mesh, Edge edge)
        {
            Face res = null;

            foreach (var face in mesh.facesInternal)
            {
                var edges = face.edgesInternal;

                for (int i = 0, c = edges.Length; i < c; i++)
                {
                    if (edge.Equals(edges[i]))
                    {
                        return(face);
                    }

                    if (edges.Contains(edges[i]))
                    {
                        res = face;
                    }
                }
            }

            return(res);
        }