It's easy to understand if we break up the sentence into its pieces. Stripping away the modifiers, the sentence is just
"In ways their parents had been hard on them".
"Different" is an adjective that modifies "ways", implying that the ways were different for each child. "Defining" is another adjective that also modifies "ways", implying that the ways had a strong effect on each child - so strong that they had a permanent effect on each child, thereby "defining" the character of each one.