It’s fairly certain that Microsoft won’t be supporting XNA for non-Windows Phone platforms, so I decided to take some time to port my game to MonoGame. Just recently, the MonoGame team has released MonoGame 3.0 which includes full support for the Windows 8 Store. Follow these meager instructions to get yourself started with doing that. If you’re lucky like I was, there’s a chance that your code is almost a 100% carry-over to the MonoGame libraries.
- Download MonoGame 3.0 Installer
- http://monogame.codeplex.com/releases/view/96421 (This guide was written with MonoGame 3.0 (BETA)
- Install the .msi so that you get the correct libraries and project templates
- Create New MonoGame Project for Windows 8 Store
- Using Visual Studio 2012, create a new MonoGame project under Visual C# –> MonoGame –> MonoGame Game
- Manually Copy Code and Change References
- Make sure MonoGame is referenced using the Windows 8 lib at C:Program Files (x86)MonoGamev3.0AssembliesWindows8MonoGame.Framework.Windows8.dll
- Copy classes and files to the new project so that it mirrors the hierarchy of your XNA 4.0 project
- Any libraries that are referenced which were compiled against the full .NET Framework will need to be recompiled against the .NET Core Framework (a subset of the .NET Framework that Windows Store Apps will reference)
- Compile and fix any errors generated because of references to things that are no longer supported by Windows Store
- Copy serialized .xnb files manually to the output directories of your MonoGame project (this is required because the Content Pipeline is not supported in Visual Studio 2012)
Some of the errors that I got were references to Close() method calls on streams (removed in .NET Core) and setting DTD validation on XmlStreams (also removed in .NET Core). See the link in the references section for an overview of the changes in .NET Core. Also, MSDN will have little green bag icons next to anything that is supported in the Window Store.