Corrected default value for retVelocity. Formatted code.