Polygon: groupMath pts: Vec2[] transform(m: Mat4 ): Polygon bbox(): Rect area(): number clone(): Polygon collides(shape: ShapeType | Vec2 ): boolean contains(point: Vec2 ): boolean raycast(origin: Vec2 , direction: Vec2 ): RaycastResult random(): Vec2 cut(a: Vec2 , b: Vec2 ): [ Polygon | null, Polygon | null ]