A wide-ranging plan to improve welfare also enshrines in law that animals can experience emotions.