This is a simpler version of the code that was posted on Frambozenbier.
It isn't really a complete game, but there is one invading Raspberry Pi and you can move the cannon with the left and right arrow keys and fire a laser with the "up" key. You might find some of the code useful.