addScaledVector method
Scale a vector and add it to this vector. Save the result in "target". (target = this + vector * scalar) @param target The vector to save the result in.
Implementation
Vec3 addScaledVector(double scalar, Vec3 vector, [Vec3? target]) {
target ??= Vec3();
target.x = x + scalar * vector.x;
target.y = y + scalar * vector.y;
target.z = z + scalar * vector.z;
return target;
}