Rigid body moving the direction the camera is pointing at

Hi, can anyone tell me how do I make my player move the direction my freeLock camera is looking at without changing to much of the script?

Rotate your input vector by the rotation of the camera:

inputVector = Camera.main.transform.rotation * inputVector;