 Yuan Dan initially joined Emperor Xiaowu on his flight, but quickly abandoned Emperor Xiaowu and returned to Luoyang.After Gao entered Luoyang, he had Yuan Dan assume acting imperial powers, and Yuan Dan began to become arrogant, viewing himself as the next emperor.Gao, who was in fact looking for a new emperor to replace Emperor Xiaowu, felt that Yuan Dan was inappropriate, and therefore, under the excuse that a cousin should not succeed another, chose Yuan Shanjian and declared him emperor (as Emperor Xiaojing).