How did improvements in agriculture in the countryside likely affect the lives of townspeople?