you can add variables to your link.. something like this:
<a href=cart.php?game_id=1&action=add><img src=game_1.jpg></a>
now, on cart.php, just create the logic to add a game to the cart.
are you using sessions to remember what is in the cart? or maybe a table in mysql?
the way to increment the number of 'game 1' purchased would probably best be done with a qty variable.
maybe you can make an array .. something like this:
$item[0][name] = 'game_1']
$item[0][qty] = 1
then when you want to increment it,
$item[0][qty]++