Sorry about the losses! Its hard at first when starting out as a newbie at incubating. Thats how you gain experience and knowledge about the entire process. Dont give up! Its bound to get better as you learn what to do and what to look for during the entire incubating process.
It seems like the little duckling was getting ready to hatch, mamma hen possibly tried helping it or she accidently cracked the egg. Its easy for eggs to get contaminated with bacteria especially before the yolk has been drawn in its navel. That last picture didn't look good for the duckling. Did you wet the membrane so the contents were visible? If not, then the contents of the unabsorbed egg spilled into the airsack. There should have been some veinage. If the duckling didnt pip a hole into the membrane, then it was suffocateing and thats what the twitching was about...or just dying from being sick from contamination. In any case, if you see clear or nearly clear veins on the membrane and the chick didn't pip the airsack, then it is suffocateing and needs help right away. Typically a the birds head and beak is under its wing, and its neck contracts shoving its beak through the wing towards the airsack, pecking a hole. Its a very complicated and precise process. The baby bird nearly suffocates twice during hatch. First near suffocation, causes contractions within the neck to peck the membrane of the airsack. The seconed near suffocation, causes the same contractions to peck the initial hole in the shell.It is hard for them to do that if they are weak, sick, or are positioned the wrong way, such as neck and head pointed down. Sometimes they can drown in their own fluid from too much humidity, or maybe the membrane is to dry and sticks to the babies from not haveing enough humidity. They cant move in the shell. It just takes patience and experience. We all have been there, when we loose many babies, have no hatch, and sometimes these eggs are very expensive
In any case, seems to me as if the egg became contaminated, infecting the yolk, therefore it broke and caused the little guy not to make it.
The eggs you had in the incubator, I guarantee became contaminated from that one rotten egg you took out.
This site should hopefully help and for future candling purposes. Kind of like a gauge to compare Chicken egg stages too.
chickscope.beckman.uiuc.edu/.../egg_to.../development.html