>>Cicadas can remain underground for as long as 17 years before emerging into the sunlight, where they survive for just a few weeks, enough time for the insects to mate and lay eggs. But right before they crawl out of the earth, some cicadas get infected with various species of the fungus Massospora—and things start to get freaky. The fungus takes over the cicadas’ bodies, eating through their limbs. It also makes the males sex-crazed. They frenetically try to mate with anything they can find, even after their genitals and butts have literally fallen off.<<
Fungi and other animal parasites often take control of their hosts’ behavior; it’s a good way to increase transmission of the disease. However, spores later emitted are from their mummified carcasses, but Massospora fungi spread their spores while the victims are still alive.
https://www.smithsonianmag.com/smart-news/fungus-causes-cicadas-mate-crazy-even-after-their-butts-fall-180972519/