Skip to content

2.14 • Mathematical operators!

Latest
Compare
Choose a tag to compare
@KyNorthstar KyNorthstar released this 24 Mar 04:55
· 2 commits to production since this release
e485150

You can now add, subtract, multiply, or divide any 2-Dimensional value against any value of its Length type.

CGPoint(x: 7, y: 12) + 11  ==   CGPoint(x: 18 y: 23)
CGPoint(x: 7, y: 12) - 11  ==   CGPoint(x: -4 y: 1)
CGPoint(x: 7, y: 12) * 2   ==   CGPoint(x: 14, y: 24)
CGPoint(x: 7, y: 12) / 2   ==   CGPoint(x: 3.5 y: 6)

Patches

Full Changelog: 2.13.2...2.14.0