External habits formation and the environment