I searched for a good answer to this all day, and since this is at the top of google when you search ‘c4d train rig’, I thought I’d post my answer to the problem here.
My solution was to apply bones down the middle each train car, putting the start and end points where the wheels should be (front, and back). There should also be a bone extending from the back wheels of each car, to the front wheels of the car behind it. Having the bones at the location of the wheels is PIVOTAL (pun intended).
The start of the bone chain should be constrained to the path, but the rest of the bone chain can’t be constrained to it. So: this is where I was getting hung up. To simulate each bone being constrained to the path, constrain nulls to the path/spline at each location of a bone joint intersection. Then, tell that bone to ‘look at/target’ that null. Every bone must have a look at null for this to work, including the first bone in the chain. You have to fiddle a bit with percentages to get it perfectly right.
Tip: You want to have your spline path finalized before you do this rigging, because it is based on percentages. If you change the path, the actual location of each null will change.
Once you have your distance between each bone figured out using percentages on the nulls, make sure they are keyed, and you can duplicate those farther down your timeline, and your train will be able to animate consistently without spreading apart. You don’t want to try re-keying them, you already did the labor intensive work of figuring out what percentage on each null = what distance, just re-use that information.
So, in conclusion:
Step 1: Bones placed at wheels
Step 2: Path constrain bone chain root
Step 3: Path constraint nulls at bone intersections
Step 4: Bones ‘target’ the null at the beginning of the next bone in the chain.
Step 5: Keyframe ‘path constraints’, duplicate and slide keys down timeline to animate
Step 6: World domination