int frames=250, totalSegments=3, cols, rows, dir; animatedPolygon[] aps; float t, new_t, offSet, partialSegment, fullSegments; // color[] palette = { #ECD27C, #BCD38D, #689D7E }; color[] palette = { #FCBF05, #E00072, #007D98 }; color bg = #120930; void setup() { size(500, 500, P2D); int i = 0; int cellSize = 100; cols = int(width/cellSize)-2; rows = int(height/cellSize)-2; aps = new animatedPolygon[rows*cols]; for (int y=0; y