There are different ways in which settings can function as character. First of all, the history associated with a certain place imbues it with memories and facts that literary characters will be aware of and relate to, and this creates a relationship between the history of a character and the history of the location/setting. Secondly, the description of a setting can give it qualities that make it seem as though the setting contributes to the action of the story. For example, in "The Haunting of Hill House" by Shirley Jackson, the house is described as being almost like a sentient being, with emotions and consciousness, and creates a mood within which the characters behave in particular ways that drive the narrative forward, as in this passage which occurs just before the visitors decide to start telling ghosts stories:
"Mrs. Dudley‟s good dinner and an hour‟s quiet conversation had evaporated the faint air of unreality and constraint; they had begun to know one another, recognize individual voices and mannerisms, faces and laughter; Eleanor thought with a little shock of surprise that she had been in Hill House only for four or five hours, and smiled a little at the fire. She could feel the thin stem of her glass between her fingers, the stiff pressure of the chair against her back, the faint movements of air through the room which were barely perceptible in small stirrings of tassels and beads. Darkness lay in the corners, and the marble cupid smiled down on them with chubby good humor."