I'm drawing vertices in the editor as gizmo spheres however the positions are always stationary, never moving when I adjust the position or scale of the object it's attached to. Is there something I'm missing?
void OnDrawGizmosSelected () {
MeshFilter selectedMeshFilter = (MeshFilter)gameObject.GetComponent("MeshFilter");
Mesh mesh = selectedMeshFilter.mesh;
Vector3[] vertices = mesh.vertices;
Color[] colors = new Color[vertices.Length];
for (var i = 0 ; i < vertices.Length ; i++){
Gizmos.DrawSphere (vertices*, vertexSize);*
*}*
*mesh.vertices = vertices;*
*mesh.RecalculateBounds();*
*}*
*```*