Hi, Welcome to JustAnswer. I am a licensed veterinarian and I'm here to help you. I am so sorry for your loss of Billy, and you have my deepest empathy! Over the years I have enjoyed several little hamsters, and losing each one was so difficult (to say the least).
It sounds to me from what you have described that Billy had some kind of tumor (benign or malignant) that grew and did not continue to have a good healing blood supply. This does happen quite often with tumors and the centers become very necrotic and smelly.
In little animals like hamsters, these tumors can be quite debilitating very quickly because they are so small. The tumors just "over take" the animal, and it sounds like this was happening for Billy. Not only was his leg involved, but also his chin.
Does this seem to match what you were seeing with Billy?
As to the cause of the tumor(s), this may have been a mammary gland tumor. That would be my best guess from what you have described and from what I have experienced.