A character structure is a system of relatively permanent traits that are manifested in the specific ways that an individual relates and reacts to others, to various kinds of stimuli, and to the environment.
On the other hand, a child whose nurture and/or education are not ideal, living in a treacherous environment and interacting with adults who do not take the long-term interests of the child to heart will be more likely to form a pattern of behavior that suits the child to avoid the challenges put forth by a malign social environment.
The means that the child invents to make the best of a hostile environment. Although this may serve the child well while in that bad environment, it may also cause the child to react in inappropriate ways, ways damaging to his or her own interests, when interacting with people in a more ideal social context. Major trauma that occurs later in life, even in adulthood, can sometimes have a profound effect.
However, character may also develop in a positive way according to how the individual meets the psychosocial challenges of the life cycle.
Just enter the terms you are looking for.