1) is stronger.
The i5-8400 has a passmark rating of 11698 and a single thread rating of 2334.
The 2400G rating is 9270 and the single thread rating is 1927
The single thread performance is likely most important for games.
As to cooling, both are 65w tdp units.