I found a glitch.
If you die in battle, then start a new game or open a save file, then you start at the location you were supposed to start at, but it plays the battle victory music and shows the gold and experience you would have gotten from the battle you just lost. They you warp to the location that you were when you entered the battle.