I'm a parent and I could say it's at least hereditary but more on the habits of the parent and depends on how mature the child is.
Hereditary is just minor but most habits of the parents are usually copied by kids even if it's wrong that's why most of the time, let's say a parent is a criminal, the child becomes a criminal too because children copy what they see.
If the child isn't matured enough to know what's right and wrong then most of the time he would grow up the same as what the parent do.