I would well imagine they were far more concerned with swimming to safety, then doing a proper full shutdown and tie down after coming to a stop.
Reportedly, they saw the water rising, went into emergency, but did not stop until they were well into the water.
From that point, even if the roadbed was still stable, scouring under the track and wheels would quickly undermine the roadbed, and once that happens, mother gravity does the rest.
As for the locomotives, probably a good chance they self-shutdown when the oil pressure dropped as they rolled over, so hopefully no water injestion. Might help in the salvage and recovery ...