Another vote for walkaway, unless you can get it for a very (and I mean very) good deal. And the rest of it is in good to excellent shape.
Consider the engine trashed, no matter what they tell you. A complete replacement. Don't just figure on a long block. Figure on replacing everything in the engine compartment including alternator, starter, injector pump, injectors, heat exchanger,exhaust manifold, etc., you get the drift. Plus a lot of labor charge. If you get it you might as well have it done right and won't have to worry about the engine or accessories for a long time.
I know nothing about the rot and that might just be the show stopper no matter how good the deal.