"AI and generally how to manage the game" has nothing to do with whether a game is DirectX or OpenGL (or an old DOS game, for that matter). It's all about how you chose to architect your engine. I can't remember their names right now but I've seen OSS Super Mario World clones, Sim City (the firts two, if I remember correctly) clones, Civilization, various FPS clones... Heck, Quake 3 is open-source these days (has been for a while). Most of those use OpenGL, but that doesn't have anything to do with how they run their AI, and even at the render level GL is close enough to DX that you can get a good idea of how to manage things like surface batching and the like. Just Google for "open-source games" and you should find a bunch of projects.