At that time, the Ming Dynasty was already at sunset, the eunuchs were in power, and the society was dark and turbulent. Except for the period of Zhu Yuanzhang, it was not as declining as the next generation. So it gave foreign enemies the opportunity to invade. In any case, the demise of the Ming Dynasty is doomed. In fact, the demise of many dynasties is doomed. Maybe, just like people, life has come to an end and there is no chance of recovery.
Most emperors have such a fate. If they are lucky, they can carry on the family line and pass on the throne to their son. If you are unlucky, you will be killed by others or your own son. Of course, you need to kill yourself if necessary.