The shapes are generated by a function which calculates the point of the polygon depending on the number of edges and the scale of the shape.