Evolutionary prisoner’s dilemma game in flocks