Before I could start on my game project, I needed a game engine. I looked at a number of examples on the internet and found an excellent site that had a step by step guide and explanation of how it's done. I can't find the original tutorial but it was somewhere on Andy Beaulieu's site

This was the basis of my engine with some changes of my own. This example may not seem much, it's just 2 boxes floating around the screen but the infrastructure underneath is quite significant.