Have you read anything about Eberron? Use the Lightning Rail and have the prisoner's friends to come try to break him out. You can have fighting inside, climbing up to the roof, running along the train cars to escape. You could even set it up to happen over days. The ruffians try to get on the train and are driven back. Later they manage to cause some damage to the train car where the prisoner is. The third time they blow a whole in the wall. The prisoner then tries to flee outside (either jumping from the train or trying to get on top) where he can rejoin the ruffians and kill the party.
If you had fights on the ground and on the train, I would have the train move every on initiative 20, 10 and 0. Or just 10 and 0. It could allow cool tactics such as bullrushing someone off the train right before the train moves again leaving that enemy several cars behind. It can help buy time to focus on the more important threats.
You could even have some big giant monster attack during the final fight. The party and enemies need to band together to fight off the monster. Then depending on what happens the PCs may let the prisoner escape, fight to capture him again, he may die fighting the monster, or the party may do something unexpected.