docs: public static float vectorToScalarScroll(float _Dx, float _Dy, float _X, float _Y) {
          // get the length of the vector
          float l = (float) Math.sqrt(_Dx * _Dx + _Dy * _Dy);
  
          // decide if the scalar should be negative or positive by finding
          // the dot product of the vector perpendicular to (_X,_Y).
          float crossX = -_Y;
          float crossY = _X;
  
          float dot = (crossX * _Dx + crossY * _Dy);
          float sign = Math.signum(dot);
  
          return l * sign;
      }