Thoughts about setup and deployment issues, WiX, XNA, the .NET Framework and Visual Studio
All postings are provided AS IS
with no warranties, and confer no rights. Additionally, views expressed
herein are my own and not those of my employer, Microsoft.
Note - there is now a simpler set of steps to create a game with a localized title, and I have written a newer blog post with updated steps. Please refer to http://blogs.msdn.com/b/astebner/archive/2010/12/10/10103522.aspx for more details.
Recently, a user posted a question on the XNA forums asking how to localize the name of their Windows Phone game. They were attempting to follow the How to: Localize an Application Title for Windows Phone tutorial in the Windows Phone documentation, but were running into some issues. That tutorial contains instructions for localizing the title of a Silverlight application, but the steps are a bit different for XNA games. I also found some of the steps to be vague and/or confusing while I tried to work through them on my own.
I’ve created an updated set of steps that can be used to localize the name of a Windows Phone game created with XNA Game Studio 4.0. I also uploaded a sample solution that implements these steps.
The steps below and the sample solution that I have created both require that you use Visual Studio 2010 Professional, Premium or Ultimate because the steps require a version of Visual Studio that supports creating a solution that contains both C++ and C# projects. The VS 2010 Express Editions do not support this.
Step 0 – Create a Windows Phone game project
Step 1 – Create a language-neutral native resource DLL
Note - the name of the native resource DLL is important in this scenario. It must be named AppResLib.dll, and the localized versions must be named AppResLib.dll.*.mui. If they are named differently, your game will be rejected by the Windows Phone Marketplace certification process.
Step 2 – Create an English (US) native resource DLL
copy "$(OutputPath)$(ProjectName).dll" "$(OutputPath)\AppResLib.dll.0409.mui"
Step 3 – Create native resource DLLs for other supported languages
Step 4 – Add native resource DLLs to your Windows Phone game project
Step 5 – Make your Windows Phone game project dependent on the native resource DLL projects
Step 6 – Update your Windows Phone game to load title strings from the resource DLLs
Update the application title by doing the following:
Update the tile title by doing the following:
The tile title is the name that is displayed if you click and hold on your application/game in the Windows Phone OS and choose to pin it to the start menu. There is some additional information about these properties and how to configure them in XNA Game Studio games in this documentation topic. Depending on the scenarios you want to support for your game, it may not be necessary to create separate strings for your application title and tile title. If you plan to use the same string for both, you do not need to create separate entries in the string table in each of your native resource DLLs in the instructions above.
Step 7 – Rebuild your Windows Phone game solution
Rebuild the solution that contains your Windows Phone Game project and your resource DLL projects. When doing so, make sure that the Windows Phone Game project is set as the startup project (as opposed to one of the resource DLL projects or your content project).
<update date="10/15/2010"> I found out today that the ingestion process requires that the resource DLL be named AppResLib.dll, so I've updated the steps in this post to reflect that, and I've posted an updated sample solution. </update>
<update date="1/18/2011"> Added a stronger warning about the naming of the DLL needing to exactly match what is listed in the documentation. </update>