Through your description, it sounds like your niece may have had unstable slipped capital femoral epiphysis. That’s the long way of saying, it sounds like the upper part of her femur (thigh bone) slipped out of place and was causing a lot of pain.
The school of thought for children who have this disorder should have surgery within 24 hours of the first symptoms, if possible. This increases the chance of success and decreases the chances of complications. However, about half of children with unstable slipped capital femoral epiphysis do develop a complication called osteonecrosis or bone death. The blood that supplies nutrients to the bone cells is not flowing to those cells and the cells die.
Treatment of osteonecrosis varies according to the problem, but surgery is frequently done.