Oh my, many an uninformed person here.
I've been there, done that, since I have 6 of these trucks, ranging from 1989 to 1999.
The 12v in your 98 should be checked for the KDP (Killer dowel pin). This is a dowel pin in the timing case which can works its way out of the case and fall into the timing gears. Part of the time it falls harmlessly into the oil pan and causes no other problems. The other part of the time it gets jammed into between the gears and cracks the timing case. This gives you a huge oil leak and is a real pain to repair as you must pull the front end off the truck, except for the fenders, to get the camshaft out so you can replace the timing case. This malady affects Cummins engines form 1989 up through 2000, no matter how many valves. It seems that when Cummins changed the design to make the dowel pin hole tighter they did not cut off production and start new, they just mixed the new design in with the old, so you may or may not have an affected engine in 1999-2000 trucks.
Other than that, the 12v engines, with the P7100 injector pump (94 to 98.5), are practically bulletproof.
In the case of the 24v, the VP44 injector pumps can be problematic, and will cook themselves over time if they do not have sufficient fuel pressure. This is due to the design, in that the VP44 pump uses the extra fuel being pushed to it to lubricate and cool the injector pump, unlike the P7100, which uses motor oil to lubricate and cool the pump. If you have a 24v, and do nothing else to it, you should install a fuel pressure gauge and monitor it. If it falls below 7 psi at wide-open throttle, replace the lift pump (fuel pump), which is located on the side of the engine, just above the starter, not in the fuel tank. Nowadays, if you go to replace the lift pump, and try to purchase it from Dodge, you will find that they superseded the design, finally, and have a retrofit kit that does put the lift pump in the tank. They no longer offer a replacement pump for the one on the side of the engine. This solution has not proven to be much better than the stock pump on the side of the engine.
If you want to keep the lift pump on the side of the engine you can still purchase if from a Cummins dealer. The best way to fix this, once and for all, is to install an aftermarket pump, such as a FASS, which is a much heavier duty pump that was specifically designed for this usage. After my second lift pump on the 99, I went to a FASS and never looked back.
If you are looking at a 24v engine, between 1998.5 and 2001, take a close look at the engine block. There may be a casting number under the PS pump, just above the oil pane flange, that says "53". If there is a "53" there, this is a thin-walled engine block, made in Brazil. Trucks with this block, used for heavy towing may crack horizontally down the passenger side of the engine, below the head, above the freeze plugs. I have talked to many people about this block, and experienced it personally. I would not buy a truck that has a 53 block, but that will be up to you. Many people have this block and have had no problems with it, even after more than 100K, but I cracked mine pulling a tractor over a mountain with 75K on it. It never cracked while drag racing, but that towing sure did it in. You do not lose functionality of the engine, just develop a water leak of varying size.
Everything I have stated here can be verified on several different web sites, and more info is available if you want to know. Just do searches on the various terms I have mentioned and you can't miss the info.
Chris