I have a 1998 Jeep Cherokee. The idle is a little rough, and when accelerating the RPMs jump around and the car jolts. There is an fairly clicking sound when the bucks. It also is throwing a P1391 code (Intermittent Cam or Crank Position Sensor). I have replaced both the distributor and the Cam sensor.
Any ideas?

classic signs of a worn timing chain, data from the sensors confuses the computer and trips that code.