blockly > utils > Coordinate > sum
utils.Coordinate.sum() method
Returns the sum of two coordinates as a new Coordinate.
Signature:
static sum(a: Coordinate | SVGPoint, b: Coordinate | SVGPoint): Coordinate;
Parameters
Parameter | Type | Description |
---|---|---|
a | Coordinate | SVGPoint | An x/y coordinate. |
b | Coordinate | SVGPoint | An x/y coordinate. |
Returns:
A Coordinate representing the sum of the two coordinates.