I have list of corners (currently 4 points) and im trying to generate polygon basing on that
I tried various methods and faced various issues
one of the ways i used to do it, was to spawn grid of vertices, outline the polygon, and make it so only vertices inside polygon area are added to mesh.vertices
result:

here the problem is that the edges are not smooth.
i guess the issue is that i used very unusual method to do this
but on the other hand i havent heard of any ‘usual’ method to write polygon vertices/triangles array
any help appreciated
… wat …
I’m quite confused as to what you’re trying to create, or even exactly what’re currently doing.
If you want to create a mesh quad, you create a mesh quad. That can either be an actual quad topology mesh, or the default triangle mesh made of two triangles.
Either way you start by making a new mesh, add the 4 vertices, and then for a triangle mesh quad add the 6 indices for the two triangles.
Mesh mesh = new Mesh();
mesh.vertices = new Vector3[] { corner0.position, corner1.position, corner2.position, corner3.position };
mesh.triangles = new int[] {
0, 1, 3, // first triangle
1, 2, 3 // second triangle
};