a bit of VEX
//Create a line with points
int pt_max = chi("Point_Max"); float length = chf("Length"); vector dir = chv("Direction"); dir = normalize(dir); vector offset = chv("Offset"); float stepVal = length / (float)(pt_max-1); int pts_all[]; resize(pts_all, pt_max); for(int i = 0; i < pt_max; i++) { vector pos = dir * (stepVal * i) + offset; int curId = addpoint(0, pos); pts_all[i] = curId; } //addprim(0, "polyline",pts_all); for(int i = 0; i < pt_max-1; i++) { addprim(0, "polyline", pts_all[i], pts_all[i+1]); }
//make it circle!
float gradiant = (float)@ptnum/(float)(@numpt - 1); @P.y = sin(gradiant * 2 * $PI); @P.z = cos(gradiant * 2 * $PI);