Also best way to implement Vec2.plus(other:Vec2) `...
# getting-started
s
Also best way to implement Vec2.plus(other:Vec2)
Copy code
inline operator fun plus(scalar: Float) = Vec2(x + scalar, y + scalar)
inline operator fun plus(other: Vec2) = Vec2(x + other.x, y + other.y)
👍 1