In 1662, at the age of 39, Koxinga died of malaria. Some people said that he died in a sudden fit of craziness when he heard about the death of his father under the Qing. His son, Zheng Jing, took control as the ruler of Taiwan, with the name of Prince of Yanping.