Main image of article XNA is Dead; Long Live MonoGame
Back in January, Microsoft announced it was going to phase out XNA, the development framework that powered Xbox development. It also said it was no longer evolving the DirectX API, which has been the main technology for Windows games for the last 17 years. The announcement about DirectX was quickly retracted and a followup email indicated that DirectX development would continue and be better integrated into Visual Studio. xnaBut the way that communication was handled brought concern from developers about the direction Microsoft was going with Windows 8 and other technologies, such as Silverlight, which as a Flash competitor seemed to have no place in the HTML5 future. Investing a year of your life to learn a new technology only to watch it wither on the vine leaves a bad taste in the mouth. Both XNA and Silverlight died before their seventh birthdays. Too bad for the team at Mono that developed Moonlight, the Linux version of Silverlight. Development is an expensive process and Microsoft giving the impression that its lost direction does not inspire confidence. A similar situation is happening with Windows development: For years, Windows developers understood the platform and the direction it was going. With Win 32, GUI developers used Visual Basic and switched to VB.NET (albeit reluctantly) or C#. C++ developers had it a bit rougher after .NET came along and yet most of Microsoft's flagship software (such as Windows and MS Office) is built with it. Now with Windows 8, the future for Windows developers seems less certain. One team of developers that probably isn’t too concerned about XNA's demise is the group behind MonoGame. Started in 2010 as XNATouch, MonoGame is a free, cross-platform open source implementation of XNA 4 that works on Windows 7 and 8, Windows Store, Windows Phone 8, iOS, Android, Mac OS X and Linux, plus PlayStation Mobile for 2D development. Versions using Google Chrome Native Client and for Raspberry Pi are also in the pipeline. Windows is still probably the best platform for development tools but its importance as a game platform appears to be in question. Microsoft needs to get its act together regarding the future of DirectX and Windows as a platform for development and running games.


MonoGame is a collection of open source packages that run on .NET or Mono. It includes OpenTK -- a C# wrapper for OpenGL, OpenCL, and OpenAL, and SharpDX (an open source implementation of DirectX for .NET). The mobile versions are based on MonoTouch which is now Xamarin, so you'll need to buy the appropriate Xamarin license for mobile development (other than for Windows). Infinite Flight on iPhone and Android is a classy demonstration of MonoGame in action. Infinite Flight For use on Windows, you'll need to download Windows XNA Game Studio and Visual Studio (either Express or the full version will work). The game studio is needed to compile content into the .xnb format. Thankfully, the MSDN XNA developers material is still up there. But for how long? To write games under XNA or MonoGame you develop in C#, as opposed to C++ for DirectX. In XNA, you can draw a sprite on the screen with just a few lines of code for each frame. Here’s an example from Microsoft. It overrides the virtual method Game.Draw. protected override void Draw(GameTime gameTime) { graphics.GraphicsDevice.Clear(Color.CornflowerBlue); // Draw the sprite. spriteBatch.Begin(SpriteSortMode.BackToFront, BlendState.AlphaBlend); spriteBatch.Draw(myTexture, spritePosition, Color.White); spriteBatch.End(); base.Draw(gameTime); } This simplicity is the reason many were drawn to XNA. It made Xbox Live Games (XBLig) a viable way for developers to make some money. Now MonoGame provides an escape route off the Xbox and Windows platforms to mobile. Monogame isn't the only XNA clone; the ANX framework is another one, and it's already been successful with Whac-A-Hamster, which was accepted in the Windows 8 store, even though the framework’s still in Beta. ANX is only for Windows, and it improves on XNA's use of DirectX9 instead of using DirectX10 (or soon DirectX11), as MonoGame does. But ANX will support OpenGL in the future. whac-a-hamster Microsoft always seems to miss obvious ways to build up support for technologies from developers. It gives away great compilers with the Visual Studio Express tools, but it stopped short on technologies like Silverlight and was forever tinkering with XNA until it stopped that too. Silverlight could have had far greater uptake had it been available with Visual C# Express. And why not build DirectX into Visual C++ Express?