Point centerRight(Point origin)

The point at the center of the right edge of the rectangle described by the given point (which is interpreted as the top-left corner) and this size.

See also Rect.centerLeft.

Source

Point centerRight(Point origin) => new Point(origin.x + width, origin.y + height / 2.0);