I for one recommend building an i7 box and really anything from that generation are still really good CPUs if youre making a gaming box. Otherwise you may run into RAM costs or some other high hardware costs.
That doesn't mean anything at all. The i7 is a family of CPUs which can be anything from a 2009 i7-860 (with DDR3 support only) to a 2023 i7-14700k (with DDR5 support). Insane performance difference.
As long as you give the older CPU enough RAM, an SSD, and a good GPU, it probably is sufficient unless your doing sim-heavy games where you want the simulation speed to be maxed out (e.g. HoI4 later years max speed simulation)
Honestly buying a 15 years old CPU is just an own goal when it will be outperformed by any modern budget i3