There are a no of games with free released source code. eg Doom I,Freecraft (like warcraft from Blizzard),Dink Smallwood(A great RPG),Duke Nukem 3d(old) etc. Yes, they are available for free downloads ,I got them from a no. of Magazine CDs.
Most of them are written in C/C++ programming...