List all the pros and cons of both machines and choose one.
Think about how long do you want to use the laptop and if you really need a laptop for gaming. The issue with PC/laptop gaming is that it costs a lot, if you always want to play with the latest games. The graphics card in the MSI is a mid range one, so not the strongest to begin with and it's a year old model already. Graphics cards age faster than milk, in laptops you can't upgrade them either.
For gaming i'd get a console, a PS5. Console generations last 7 years, for that tenure you're set from the price of a top range graphics card. You don't need to spend the price of the console on a new graphics card in every 2 years to be able to keep up with the pace.
As long as these two processors go, it's not that black and white that this specific i7 (i7-1065G7) is better than the i5 (i5-9300H). Take a look at comparison tests. In 3D rendering the i5 in the MSI is better, it scores higher on Cinebench 15 too, while the i7 is newer and doesn't need that much power. The area where this i7 shines is the iGPU, that's two times faster than in the i5.
The rest of the specs are pretty self-explanatory, whether the 256 GB storage capacity is enough or it would be better to have double the capacity. Whether you want to get something smaller, more lightweight, which is easier to carry or a more robust machine with bigger screen.