I did some research of those 2 processors and basically the i7 is about 2x better (faster, better scores etc) than the i5. For future proofing, always get the best you can afford. The i5 will work fine for most applications, but the quad core will be useful for processor intensive things like gaming, video/audio conversion etc. My laptop has the i7 and its pretty nice. The i7 has better graphics also.
From a pure game perspective, you want the laptop with the more powerful GPU. In this case it would be the GT 765m. While it is paired up with only a dual core i5 CPU that laptop will generally perform better than the GT 740m and the quad core i7 CPU.
Starcraft 2 is one of those few games that are more CPU intensive than GPU intensive. At low graphic settings the game will likely perform better on the i7 laptop than the i5 laptop because the GT 740m will not be bottlenecked. However, I believe if you turn up the graphics quality the game will perform better on the i5 laptop because the GT 765m would be powerful enough to maintain higher frame rates.
In a game like Skyrim which is both CPU and GPU intensive, that game will definitely perform better on the i5 laptop with the GT 765m than on the i7 laptop with the GT 740m.
For games like BioShock Infinite, which does not really care how powerful the CPU is as long as it does not bottleneck the GPU, they will perform better with the i5 + GT 765m laptop.