The event first happened on
Gaming.SE Arqade last year, and the blog post announcing it starts with:
Throughout history, men have worn hats as a way of showing how much better they are than other men. “I buy hats,” a behatted man seems to say. “I am better than you.”
In wartime, hats were a useful way of conferring rank, and ensuring that casualties were confined to the lower classes… During peacetime, hats have been instrumental for men to let the non-hatted know just who is wearing the hat around here.
– The Team Fortress 2 Classless Update