Throughout the Ming dynasty, there was a war between the Mongolian tribes. So in order to keep them out and defend their territory, the emperors of the Ming dynasty used alot of their fortune to keep things stable against invasions from the Mongolians.