Aaron Stebner's WebLog

Thoughts about setup and deployment issues, WiX, XNA, the .NET Framework and Visual Studio

June, 2009

  • Aaron Stebner's WebLog

    Updated sample code that supports detection of .NET Framework 4

    • 0 Comments

    I have posted updated versions of the .NET Framework detection code that I have previously written about on my blog that now support detecting the install state of the .NET Framework 4 client and full products.  In addition, I decided to create a new landing page that introduces the 2 versions of the sample code and provides usage information and download locations.

    You can find the landing page at http://blogs.msdn.com/astebner/pages/9763379.aspx.

    The downloads for the updated sample code are listed in this landing page.  There will need to be some slight updates to this sample code when the final version of the .NET Framework 4 releases.  I will keep this code up-to-date as needed in the future.

  • Aaron Stebner's WebLog

    Link to new Object Placement on Avatars sample on the Creators Club site

    • 0 Comments

    Last week, we posted a few Avatar samples on the Creators Club site to help people get started using Avatars in XNA Game Studio 3.1 games.  We’ve just released another useful Avatar sample that I wanted to make sure everyone saw:

    As always, make sure to keep an eye out on the Creators Club site for additional sample content in the future as well.

  • Aaron Stebner's WebLog

    Link to details about sound effect API changes in XNA Game Studio 3.1

    • 0 Comments

    One of my colleagues, Ashu Tatake, started a blog last week.  This week he wrote a helpful post about updates in the XNA Framework sound effect APIs in XNA Game Studio 3.1, so I wanted to link to it here to help more people find it.

    As Shawn Hargreaves described in this blog post, we made some changes in XNA Game Studio 3.1 to fix some issues we discovered with the sound effect APIs originally introduced in XNA Game Studio 3.0.  Shawn’s post describes the scenarios, the problems we found with the 3.0 APIs, and an overview of the changes.

    Ashu follows that up by providing more detailed information about how to migrate existing 3.0 code to 3.1.  If you have any XNA Game Studio 3.0 projects that use sound effect APIs and are planning to upgrade the projects to 3.1, I encourage you to check out Ashu’s blog post for more details about how to identify which audio playback scenarios are most appropriate for your game and how to update your code to adjust for the breaking changes in the sound effect APIs in 3.1.

  • Aaron Stebner's WebLog

    Steps to upgrade an XACT2 project to XACT3 so it can be used with XNA Game Studio 3.1

    • 1 Comments

    If you have an XNA Game Studio project that includes an XACT2 audio project and plan to upgrade it to XNA Game Studio 3.1, there is an additional manual step you must take to upgrade your XACT2 project to XACT3 format.

    There is some information about this scenario in the XNA Game Studio 3.1 documentation.  Unfortunately, the documentation topics don’t list the full error message that you will see if you compile your upgraded project without also upgrading the XACT project, so searching for the error message doesn’t lead to the exact documentation topics that are intended to help in this scenario.  Hopefully this blog post will help guide folks who hit this error in the right direction.

    Description of the issue

    If you have an existing XNA Game Studio 3.0 project that uses an XACT2 audio project, then you upgrade to XNA Game Studio 3.1, you will see an error like the following in the Visual Studio error list when you attempt to compile it with XNA Game Studio 3.1:

    The .xap file was created with a version of XACT that is incompatible with the XNA Framework Content Pipeline version used by this project. Refer to the documentation for options to resolve this mismatch.

    Some guidance about this upgrade issue with XACT projects can be found in the following topics in the documentation:

    • Upgrading XNA Game Studio Projects - in the table of contents, this topic is located at XNA Game Studio 3.1 | Getting Started with XNA Game Studio | Upgrading XNA Game Studio Projects (or via this link if you have XNA Game Studio 3.1 installed).
    • Upgrade Guide: XNA Game Studio 3.0 to XNA Game Studio 3.1 – in the table of contents, this topic is located at XNA Game Studio 3.1 | Getting Started with XNA Game Studio | Upgrading XNA Game Studio Projects | Upgrade Guide: XNA Game Studio 3.0 to XNA Game Studio 3.1 (or via this link if you have XNA Game Studio 3.1 installed).

    The following information in the above topics is applicable to help resolve this XACT compilation error message:

    XNA Game Studio 3.1 projects must use the Microsoft Cross Platform Audio Creation Tool version 3 (XACT3), which is new to XNA Game Studio 3.1. The version of XACT provided with XNA Game Studio 3.0, XACT2, writes project files (.xap) that are incompatible with XNA Game Studio 3.1 projects. XNA Game Studio 3.0 projects must continue to use XACT2. Both versions of XACT are available in the Start menu, under All Programs | Microsoft XNA Game Studio 3.1 | Tools.

    How to update from XACT2 to XACT3 in XNA Game Studio 3.1

    Here are some more specific steps you can use to upgrade an XACT2 project used in XNA Game Studio 3.0 to the version of XACT3 so they can be used by an XNA Game Studio 3.1 project:

    1. On a system with XNA Game Studio 3.1 installed, click on the Start menu, choose All Programs, then Microsoft XNA Game Studio 3.1 | Tools | Microsoft Cross-Platform Audio Creation Tool 3 (XACT3).
    2. In the Microsoft Cross-Platform Audio Creation Tool (XACT) v3.0 tool, open the .xap file from the project that you upgraded from XNA Game Studio 3.0 to XNA Game Studio 3.1.  When it loads, you should see the following message in the XACT UI:

      ---------------------------
      XACT Version Mismatch
      ---------------------------
      This project file was created with the August 2007 release of XACT. You are running the March 2009 release.
      If you save this project, it will be saved as the current version and may no longer work with the version of XACT it was originally created with.
      ---------------------------
      OK  
      ---------------------------

    3. Back up your .xap file before clicking OK if you would like to keep a copy of the old project (an upgrade does not happen automatically).
    4. Click OK to upgrade the .xap project to 3.0 format.
    5. Save the .xap project in the XACT UI and close the XACT UI.
    6. Go back to Visual Studio 2008, open the project that you upgraded from XNA Game Studio 3.0 to 3.1 and choose to build it again.

    Additional notes about this error message

    The steps above explain how to upgrade an XACT2 project created with a previous version of XNA Game Studio to an XACT3 project that can be used with XNA Game Studio 3.1.  However, there are a few different scenarios where the “.xap file was created with a version of XACT that is incompatible with the XNA Framework Content Pipeline version used by this project” error message can occur, so the above workaround may not successfully resolve this error in all cases.

    Here are some of the possible configurations where this error will occur:

    • Attempting to compile an XNA Game Studio 3.1 project that includes an XACT2 project

      This is the scenario that the workaround above applies to

    • Attempting to compile an XNA Game Studio 3.0 project that includes an XACT3 project

      This is the inverse of the above scenario. You need to create a new version of your XACT project using the tool included with XNA Game Studio 3.1 at the following location on the start menu:  All Programs | Microsoft XNA Game Studio 3.1 | Tools | Microsoft Cross-Platform Audio Creation Tool 2 (XACT2).

    • Attempting to compile an XNA Game Studio 3.0 or 3.1 project that includes an XACT project created with a version of the XACT tool other than the ones that ship with XNA Game Studio 3.1 (for example, the version of XACT in the DirectX SDK)

      This is similar to both of the above scenarios.  If you’re using an XNA Game Studio 3.1 project, you need to make sure the XACT project is saved in the format of the version of XACT3 that ships with XNA Game Studio 3.1.  If you’re using an XNA Game Studio 3.0 project, you need to make sure the XACT project is saved in the format of the version of XACT2 that ships with XNA Game Studio 3.0 and 3.1.
  • Aaron Stebner's WebLog

    New XNA Game Studio 3.1 Avatar sample content is now available on the Creators Club site

    • 1 Comments

    As announced in this forum post, there is some new sample content available on the XNA Creators Club site to help you get started creating games in XNA Game Studio 3.1 that take advantage of the new Xbox LIVE Avatar development features.  Here is a quick summary of the new content:

    I also encourage you to check out the following links for more details about using Avatars in your XNA Game Studio 3.1 game:

    Make sure to keep an eye out for additional content on the XNA Creators Club site in the near future as well.

  • Aaron Stebner's WebLog

    Steps to install XNA Game Studio without using the setup bootstrapper

    • 14 Comments

    In the past, we've heard from a few people via the Creators Club forums who have had trouble getting XNA Game Studio setup to run correctly.  In a few cases, such as in this forum post, the setup program (named bootstrapper.exe) crashes shortly after double-clicking on the setup package to launch it.

    If you run into this type of issue with XNA Game Studio 2.0, 3.0, 3.1, 4.0 or 4.0 Refresh setup, you can use the following set of steps to bypass bootstrapper.exe and install the pieces of XNA Game Studio manually. 

    To manually install the XNA Game Studio 4.0 Refresh

    Note - if you are running a 64-bit version of Windows, you will need to use %programfiles(x86)% instead of %programfiles% for the installation paths.

    1. Download xnags40_setup.exe and save it to your hard drive
    2. Run xnags40_setup.exe /x to extract the contents to a folder of your choosing
    3. Go to the folder you extracted to in step 2 and run the MSI named redists.msi

      Note: This MSI will only display a small progress bar while it is installing and will not tell you when it is done.  When the progress bar disappears, continue to the next step.

    4. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v4.0\Setup\XLiveRedist.msi
    5. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v4.0\Redist\XNA FX Redist\xnafx40_redist.msi
    6. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v4.0\Setup\xnaliveproxy.msi
    7. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v4.0\Setup\xnags_platform_tools.msi
    8. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v4.0\Setup\xnags_shared.msi
    9. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v4.0\Setup\xnags_visualstudio.msi
    10. Go to the folder you extracted to in step 2 and run the MSI named arpentry.msi

    To manually install XNA Game Studio 4.0

    Note - if you are running a 64-bit version of Windows, you will need to use %programfiles(x86)% instead of %programfiles% for the installation paths.

    1. Download xnags40_setup.exe and save it to your hard drive
    2. Run xnags40_setup.exe /x to extract the contents to a folder of your choosing
    3. Go to the folder you extracted to in step 2 and run the MSI named redists.msi

      Note: This MSI will only display a small progress bar while it is installing and will not tell you when it is done.  When the progress bar disappears, continue to the next step.

    4. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v4.0\Setup\XLiveRedist.msi
    5. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v4.0\Redist\XNA FX Redist\xnafx40_redist.msi
    6. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v4.0\Setup\xnaliveproxy.msi
    7. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v4.0\Setup\xnags_platform_tools.msi
    8. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v4.0\Setup\xnags_shared.msi
    9. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v4.0\Setup\xnags_documentation.msi
    10. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v4.0\Setup\xnags_visualstudio.msi
    11. Go to the folder you extracted to in step 2 and run the MSI named arpentry.msi

    To manually install XNA Game Studio 3.1

    Note - if you are running a 64-bit version of Windows, you will need to use %programfiles(x86)% instead of %programfiles% for the installation paths.

    1. Uninstall XNA Game Studio 3.0 if you have it installed
    2. Download xnags31_setup.exe and save it to your hard drive
    3. Run xnags31_setup.exe /x to extract the contents to a folder of your choosing
    4. Go to the folder you extracted to in step 2 and run the MSI named redists.msi

      Note: This MSI will only display a small progress bar while it is installing and will not tell you when it is done.  When the progress bar disappears, continue to the next step.

    5. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.1\Setup\XLiveRedist.msi
    6. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.1\Redist\XNA FX Redist\xnafx30_redist.msi
    7. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.1\Redist\XNA FX Redist\xnafx31_redist.msi
    8. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.1\Setup\xnaliveproxy.msi
    9. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.1\Setup\xnags_platform_tools.msi
    10. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.1\Setup\xnags_shared.msi
    11. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.1\Setup\platformer.msi
    12. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.1\Setup\xnags_documentation.msi
    13. (skip this step if you do not have Visual C# 2008 Express Edition installed) Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.1\Setup\xnags_vcsexpress.msi
    14. (skip this step if you do not have Visual Studio 2008 Standard Edition or higher installed) Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.1\Setup\xnags_devenv.msi
    15. Go to the folder you extracted to in step 2 and run the MSI named arpentry.msi

    To manually install XNA Game Studio 3.0

    Note - if you are running a 64-bit version of Windows, you will need to use %programfiles(x86)% instead of %programfiles% for the installation paths.

    1. Download xnags30_setup.exe and save it to your hard drive
    2. Run xnags30_setup.exe /x to extract the contents to a folder of your choosing
    3. Go to the folder you extracted to in step 2 and run the MSI named redists.msi

      Note: This MSI will only display a small progress bar while it is installing and will not tell you when it is done.  When the progress bar disappears, continue to the next step.

    4. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.0\Setup\XLiveRedist.msi
    5. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.0\Redist\XNA FX Redist\xnafx30_redist.msi
    6. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.0\Setup\xnaliveproxy.msi
    7. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.0\Setup\xnags_platform_tools.msi
    8. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.0\Setup\xnags_shared.msi
    9. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.0\Setup\platformer.msi
    10. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.0\Setup\xnags_documentation.msi
    11. (skip this step if you do not have Visual C# 2008 Express Edition installed) Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.0\Setup\xnags_vcsexpress.msi
    12. (skip this step if you do not have Visual Studio 2008 Standard Edition or higher installed) Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v3.0\Setup\xnags_devenv.msi
    13. Go to the folder you extracted to in step 2 and run the MSI named arpentry.msi

    To manually install XNA Game Studio 2.0

    Note - if you are running a 64-bit version of Windows, you will need to use %programfiles(x86)% instead of %programfiles% for the installation paths.

    1. Download xnags20_setup.exe and save it to your hard drive
    2. Run xnags20_setup.exe /x to extract the contents to a folder of your choosing
    3. Go to the folder you extracted to in step 2 and run the MSI named redists.msi

      Note: This MSI will only display a small progress bar while it is installing and will not tell you when it is done.  When the progress bar disappears, continue to the next step.

    4. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v2.0\Setup\XLiveRedist.msi
    5. Run the EXE at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v2.0\Redist\DX Redist\DXSETUP.exe
    6. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v2.0\Redist\XNA FX Redist\xnafx20_redist.msi
    7. Go to the folder you extracted to in step 2 and run the MSI named xnaliveproxy.msi
    8. Go to the folder you extracted to in step 2 and run the MSI named xnags_shared.msi
    9. Go to the folder you extracted to in step 2 and run the MSI named spacewar.msi
    10. Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v2.0\Setup\xnags_documentation.msi
    11. (skip this step if you do not have Visual C# 2005 Express Edition installed) Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v2.0\Setup\xnags_vcsexpress.msi
    12. (skip this step if you do not have Visual Studio 2005 Standard Edition or higher installed) Run the MSI at %ProgramFiles%\Microsoft XNA\XNA Game Studio\v2.0\Setup\xnags_devenv.msi
    13. Go to the folder you extracted to in step 2 and run the MSI named arpentry.msi

    If you end up running into this type of crash, before you proceed with one of the above workarounds, please collect a call stack with Visual Studio or Visual C# Express Edition and report a bug on the Connect site so that we can investigate it further.

    <update date="8/7/2009"> Added clarification about the install step for redists.msi. </update>

     <update date="11/5/2010"> Added information about installing XNA Game Studio 4.0. </update>

     <update date="11/8/2010"> Added a note about the %programfiles(x86)% path on 64-bit versions of Windows. </update>

     <update date="2/22/2012"> Added information about installing the XNA Game Studio 4.0 Refresh. </update>

     

  • Aaron Stebner's WebLog

    XNA Game Studio 3.1 is now available for download

    • 0 Comments

    As announced today in this news item on the Creators Club site, XNA Game Studio 3.1 is now available for download.

    Getting started

    Here are some links with information about how to download and get started using XNA Game Studio 3.1:

    What’s new in XNA Game Studio 3.1?

    XNA Game Studio 3.1 includes the following new features:

    1. Support for Xbox LIVE Avatars
    2. Support for Xbox LIVE Party features
    3. Video playback
    4. Updated audio APIs for “fire-and-forget” scenarios
    5. Support for XACT3
    6. Automatic XNB serialization
    7. XNA Framework multi-targeting in the Visual Studio 2008 and/or Visual C# 2008 Express Edition IDE
    8. Upgrade wizard to convert 3.0 projects to 3.1
    9. An updated version of XNA Game Studio Connect that allows so Creators Club members will be able to deploy and debug their games on an Xbox 360.  If you previously deployed Xbox 360 games using XNA Game Studio 2.0 or 3.0 and the old version of XNA Game Studio Connect, you will need to manually delete and re-download XNA Game Studio Connect, as described in this blog post.
    10. Downloadable content (only for Xbox LIVE Arcade titles that use the XNA Game Studio 3.1 XDK Extensions)

    If you previously had XNA Game Studio 3.0 installed

    XNA Game Studio 3.1 is a replacement for XNA Game Studio 3.0, and this means that you have to uninstall XNA Game Studio 3.0 before you can install XNA Game Studio 3.1.

    Once you install XNA Game Studio 3.1, it can be used to create, build, deploy and debug both 3.0 and 3.1 projects.  Existing 3.0 projects can be opened in XNA Game Studio 3.1 just like they could in XNA Game Studio 3.0, and you are not required to upgrade your 3.0 project to 3.1.  You can also create new 3.0 or 3.1 projects in the New Project dialog in Visual Studio 2008 or Visual C# 2008 Express Edition.

    If you choose to upgrade your 3.0 project to 3.1, you can do so by opening your 3.0 project in XNA Game Studio 3.1, right-clicking on the project in the Visual Studio Solution Explorer, and choosing the Upgrade Solution… menu item.

    For more information about upgrading your 3.0 projects, check out this article on the Creators Club site.

    If you encounter XNA Game Studio 3.1 setup failures

    If you run into setup failures while installing XNA Game Studio 3.1, it can help to look at the log files created by XNA Game Studio 3.0 setup.  They are located at %temp%\XNA Game Studio 3.1 Setup\Logs.

    The best way to get help for setup issues is to gather your log files, upload them to a file server of your choice, and then post a question on the Creators Club general forum that includes a link to your log files.  When doing this, please be sure to search for related issues before posting something because your question may have already been answered.

    You can also report setup issues via the Connect site - please include your log files as attachments when doing this.

    <update date="6/12/2009"> Added a link to a new blog post by Shawn Hargreaves about audio improvements. </update>

     

  • Aaron Stebner's WebLog

    Votive support for Visual Studio 2010 beta has been added to WiX v3.5

    • 0 Comments

    As Bob Arnson recently noted, the WiX virtual team has been working on getting initial builds of WiX v3.5 posted to the SourceForge site.  The build from last week, 3.5.0605.0, includes a couple of big new features contributed by some folks on the Visual Studio team at Microsoft:

    • A version of Votive that integrates into the Visual Studio 2010 beta
    • A new set of detection properties for .NET Framework 4 beta installation states in the WixNetfxExtension
    • A new set of detection properties and registration custom actions for Visual Studio 2010 beta editions in the WixVsExtension

    You can check out these new features starting in build 3.5.0605.0, which is available at http://wix.sourceforge.net/releases/3.5.0605.0/ on the WiX SourceForge site.

    If you encounter any bugs with these new features, please report them on the WiX bug reporting site.  If you have any questions about using these new features or about WiX in general, I encourage you to use the WiX mailing lists.

  • Aaron Stebner's WebLog

    Links to download Japanese versions of Visual Studio 2010 and .NET Framework 4 beta 1

    • 0 Comments

    A couple of weeks ago, I posted links to English download locations for the .NET Framework 4 beta 1 and Visual Studio 2010 beta.  There are now Japanese versions of some of these products available for download, so I wanted to post those download links as well.

    .NET Framework 4 beta 1 Japanese downloads

    Note: The download packages for the .NET Framework 4 beta 1 and .NET Framework 4 client profile beta 1 are the same as for the English beta 1 release.  The difference is that there are now Japanese download pages.  The language pack installs on top of the .NET Framework 4 beta 1 and adds Japanese string resources for runtime exceptions and other types of error messages.

    Visual Studio 2010 beta 1 Japanese downloads

    Here are a few useful links in case you run into issues while installing or using Visual Studio 2010 beta 1 and the .NET Framework 4 beta 1:

  • Aaron Stebner's WebLog

    Possible problem publishing content with ClickOnce in XNA Game Studio 3.0 or 3.1

    • 0 Comments

    I ran into an issue in a Creators Club forum post this week that I wanted to describe in more detail here in case anyone runs into a similar issue in the future.

    In the forum post, a developer was using the animated sprite sample available in this MSDN topic as the starting point for a project, then adding some items to the content project.  Afterwards, they tried to use the Publish command to create a ClickOnce deployment package.  Installing the ClickOnce package on another machine completed, but the game would not run because the content was not deployed along with the game binaries.

    I looked at the project files included in this sample and found that the .csproj file for the Windows game is missing some metadata that is required by the ClickOnce publishing process in XNA Game Studio 3.0 and XNA Game Studio 3.1.  The Windows game .csproj includes the following ItemGroup that references the nested content project:

    <ItemGroup>
      <NestedContentProject Include="Content\Content.contentproj">
        <ContentRootPath>Content</ContentRootPath>
        <Visible>False</Visible>
      </NestedContentProject>
    </ItemGroup>

    XNA Game Studio 3.0 and 3.1 includes logic to automatically include the content in each nested content project in the ClickOnce publishing output.  This logic requires each NestedContentProject element in the .csproj to include a Project child element.  The Project element must be set to a GUID value that exactly matches the value of the ProjectGuid element in the .contentproj file for the content project (including the curly braces - if the GUID has curly braces in the game project, it must also have curly braces in the content project and vice versa).

    In the animated sprite sample referenced above, this would look like the following:

    <ItemGroup>
      <NestedContentProject Include="Content\Content.contentproj">
        <Project>8ebb2a4c-cb7d-46a7-94a2-82f45c712d12</Project>
        <ContentRootPath>Content</ContentRootPath>
        <Visible>False</Visible>
      </NestedContentProject>
    </ItemGroup>

    After adding the Project element listed in bold above to the Windows game .csproj file in the animated sprite sample, the Publish command will correctly include items that are in the game’s content project when creating a ClickOnce deployment package.

    The built-in XNA Game Studio project templates include this Project element by default and set it to the correct GUID value when you instantiate a new project.  Unfortunately, some of the older samples that we created in pre-3.0 versions of XNA Game Studio did not have that element, so it may be necessary to manually fix the .csproj by adding this information if you are discover that the files in your content project(s) are failing to deploy when using ClickOnce publishing.

    One note here – it is possible to invoke the ClickOnce Publish command in XNA Game Studio Express 1.0 and XNA Game Studio 2.0 projects, but the command will not work correctly in those versions of XNA Game Studio.  If you are running into issues with ClickOnce with older versions of XNA Game Studio, you should upgrade to at least XNA Game Studio 3.0 and try again first.  If you still run into issues, check to make sure your project has the above metadata.  If that isn’t the issue either, please contact me and/or post a question on the Creators Club Forums and we’ll be able to help you investigate further.

    <update date="7/14/2009"> Updated post to indicate that this issue can affect XNA Game Studio 3.0 and 3.1, not just 3.0. </update>

    <update date="5/27/2010"> Added a note about curly braces around the project GUID because I ran into a publishing issue recently where content was not published when the GUID in the content project was surrounded by curly braces but the GUID in the NestedContentProject section of the game project was not. </update>

     

Page 1 of 1 (10 items)