Hot sauce is not a deterent, in fact feeding cayenne powder to you chickens is often done to promote laying and add vitamins. The active ingredient, capsaicin, has not receptors in birds, only mammals. That is so the that pepper plants get their seeds dispersed because their seeds will survive a trip through a bird's digestive track, but not a mammal's.
 
A hard egg, wood or something, will deter them because they get no reward and will stop trying, at least that's the logic. I've never known chickens to learn anything easily except what looks like food.