Visual Studio 项目

Visual Studio project

我有一个在 Visual Studio 中制作的 .sproj 文件(但也许不是。我不确定)...

我有 Visual Studio Professional 2015,但我无法用它打开它...我试过 google 它,我也试过在项目 GUID 中找到它如何打开它,但没有任何帮助。

我已经安装了 Windows XNA、Visual Studio 2010 Express、gtk-sharp-2.12.38.msi、MonoGameSetup.exe、xnafx40_redist.msi 和 XamarinStudio- 6.1.2.44.msi, 但是还是打不开


这是我的 .csproj 文件:

<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup>
    <ProjectGuid>{878F44B3-F3E4-414E-A630-B550880FC216}</ProjectGuid>
    <ProjectTypeGuids>{6D335F3A-9D43-41b4-9D22-F6F17C4BE596};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">x86</Platform>
    <OutputType>WinExe</OutputType>
    <AppDesignerFolder>Properties</AppDesignerFolder>
    <RootNamespace>Plantograf</RootNamespace>
    <AssemblyName>Plantograf</AssemblyName>
    <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
    <TargetFrameworkProfile>Client</TargetFrameworkProfile>
    <XnaFrameworkVersion>v4.0</XnaFrameworkVersion>
    <XnaPlatform>Windows</XnaPlatform>
    <XnaProfile>HiDef</XnaProfile>
    <XnaCrossPlatformGroupID>3ee21cd0-475d-40e9-9b8c-8bec87480d99</XnaCrossPlatformGroupID>
    <XnaOutputType>Game</XnaOutputType>
    <ApplicationIcon>Game.ico</ApplicationIcon>
    <Thumbnail>GameThumbnail.png</Thumbnail>
    <PublishUrl>publish\</PublishUrl>
    <Install>true</Install>
    <InstallFrom>Disk</InstallFrom>
    <UpdateEnabled>false</UpdateEnabled>
    <UpdateMode>Foreground</UpdateMode>
    <UpdateInterval>7</UpdateInterval>
    <UpdateIntervalUnits>Days</UpdateIntervalUnits>
    <UpdatePeriodically>false</UpdatePeriodically>
    <UpdateRequired>false</UpdateRequired>
    <MapFileExtensions>true</MapFileExtensions>
    <ApplicationRevision>0</ApplicationRevision>
    <ApplicationVersion>1.0.0.%2a</ApplicationVersion>
    <IsWebBootstrapper>false</IsWebBootstrapper>
    <UseApplicationTrust>false</UseApplicationTrust>
    <BootstrapperEnabled>true</BootstrapperEnabled>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
    <DebugSymbols>true</DebugSymbols>
    <DebugType>full</DebugType>
    <Optimize>false</Optimize>
    <OutputPath>bin\x86\Debug</OutputPath>
    <DefineConstants>DEBUG;TRACE;WINDOWS</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <NoStdLib>true</NoStdLib>
    <UseVSHostingProcess>false</UseVSHostingProcess>
    <PlatformTarget>x86</PlatformTarget>
    <XnaCompressContent>false</XnaCompressContent>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
    <DebugType>pdbonly</DebugType>
    <Optimize>true</Optimize>
    <OutputPath>bin\x86\Release</OutputPath>
    <DefineConstants>TRACE;WINDOWS</DefineConstants>
    <ErrorReport>prompt</ErrorReport>
    <WarningLevel>4</WarningLevel>
    <NoStdLib>true</NoStdLib>
    <UseVSHostingProcess>false</UseVSHostingProcess>
    <PlatformTarget>x86</PlatformTarget>
    <XnaCompressContent>true</XnaCompressContent>
  </PropertyGroup>
  <ItemGroup>
    <Reference Include="FarseerPhysics XNA, Version=3.5.0.39428, Culture=neutral, processorArchitecture=x86">
      <SpecificVersion>False</SpecificVersion>
      <HintPath>bin\x86\Debug\FarseerPhysics XNA.dll</HintPath>
    </Reference>
    <Reference Include="Microsoft.Xna.Framework, Version=4.0.0.0, Culture=neutral, PublicKeyToken=842cf8be1de50553, processorArchitecture=x86">
      <Private>False</Private>
    </Reference>
    <Reference Include="Microsoft.Xna.Framework.Game, Version=4.0.0.0, Culture=neutral, PublicKeyToken=842cf8be1de50553, processorArchitecture=x86">
      <Private>False</Private>
    </Reference>
    <Reference Include="Microsoft.Xna.Framework.Graphics, Version=4.0.0.0, Culture=neutral, PublicKeyToken=842cf8be1de50553, processorArchitecture=x86">
      <Private>False</Private>
    </Reference>
    <Reference Include="Microsoft.Xna.Framework.GamerServices, Version=4.0.0.0, Culture=neutral, PublicKeyToken=842cf8be1de50553, processorArchitecture=x86">
      <Private>False</Private>
    </Reference>
    <Reference Include="Microsoft.Xna.Framework.Xact, Version=4.0.0.0, Culture=neutral, PublicKeyToken=842cf8be1de50553, processorArchitecture=x86">
      <Private>False</Private>
    </Reference>
    <Reference Include="Microsoft.Xna.Framework.Video, Version=4.0.0.0, Culture=neutral, PublicKeyToken=842cf8be1de50553, processorArchitecture=x86">
      <Private>False</Private>
    </Reference>
    <Reference Include="Microsoft.Xna.Framework.Avatar, Version=4.0.0.0, Culture=neutral, PublicKeyToken=842cf8be1de50553, processorArchitecture=x86">
      <Private>False</Private>
    </Reference>
    <Reference Include="Microsoft.Xna.Framework.Net, Version=4.0.0.0, Culture=neutral, PublicKeyToken=842cf8be1de50553, processorArchitecture=x86">
      <Private>False</Private>
    </Reference>
    <Reference Include="Microsoft.Xna.Framework.Storage, Version=4.0.0.0, Culture=neutral, PublicKeyToken=842cf8be1de50553, processorArchitecture=x86">
      <Private>False</Private>
    </Reference>
    <Reference Include="mscorlib">
      <Private>False</Private>
    </Reference>
    <Reference Include="System">
      <Private>False</Private>
    </Reference>
    <Reference Include="System.Xml">
      <Private>False</Private>
    </Reference>
    <Reference Include="System.Core">
      <Private>False</Private>
    </Reference>
    <Reference Include="System.Xml.Linq">
      <Private>False</Private>
    </Reference>
    <Reference Include="System.Net">
      <Private>False</Private>
    </Reference>
  </ItemGroup>
  <ItemGroup>
    <Compile Include="ConfigXml.cs" />
    <Compile Include="LpcScale.cs" />
    <Compile Include="Pictogram.cs" />
    <Compile Include="Properties\AssemblyInfo.cs" />
    <Compile Include="Program.cs" />
    <Compile Include="Game1.cs" />
  </ItemGroup>
  <ItemGroup>
    <Content Include="config.xml">
      <CopyToOutputDirectory>Always</CopyToOutputDirectory>
      <SubType>Designer</SubType>
    </Content>
    <Content Include="Game.ico" />
    <Content Include="GameThumbnail.png" />
  </ItemGroup>
  <ItemGroup>
    <ProjectReference Include="..\PlantografContent\PlantografContent.contentproj">
      <Name>PlantografContent</Name>
      <XnaReferenceType>Content</XnaReferenceType>
    </ProjectReference>
  </ItemGroup>
  <ItemGroup>
    <BootstrapperPackage Include=".NETFramework,Version=v4.0,Profile=Client">
      <Visible>False</Visible>
      <ProductName>Microsoft .NET Framework 4 Client Profile %28x86 and x64%29</ProductName>
      <Install>true</Install>
    </BootstrapperPackage>
    <BootstrapperPackage Include="Microsoft.Net.Client.3.5">
      <Visible>False</Visible>
      <ProductName>.NET Framework 3.5 SP1 Client Profile</ProductName>
      <Install>false</Install>
    </BootstrapperPackage>
    <BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
      <Visible>False</Visible>
      <ProductName>.NET Framework 3.5 SP1</ProductName>
      <Install>false</Install>
    </BootstrapperPackage>
    <BootstrapperPackage Include="Microsoft.Windows.Installer.3.1">
      <Visible>False</Visible>
      <ProductName>Windows Installer 3.1</ProductName>
      <Install>true</Install>
    </BootstrapperPackage>
    <BootstrapperPackage Include="Microsoft.Xna.Framework.4.0">
      <Visible>False</Visible>
      <ProductName>Microsoft XNA Framework Redistributable 4.0</ProductName>
      <Install>true</Install>
    </BootstrapperPackage>
  </ItemGroup>
  <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
  <Import Project="$(MSBuildExtensionsPath)\Microsoft\XNA Game Studio\Microsoft.Xna.GameStudio.targets" />
  <!--
      To modify your build process, add your task inside one of the targets below and uncomment it.
      Other similar extension points exist, see Microsoft.Common.targets.
      <Target Name="BeforeBuild">
      </Target>
      <Target Name="AfterBuild">
      </Target>
    -->
</Project>

错误信息:

cannot by opened because its project type(.contentproj) is not supported by this version of the application
to open it, please use a version that supports this type of project

one or more project in the solution were not loaded correctly.
Please see output window for details.

这是错误日志输出:

Migration Report -`
Overview
Project    Path    Errors    Warnings    Messages
Plantograf    Plantograf\Plantograf\Plantograf.csproj    1    0    0
PlantografContent    Plantograf\PlantografContent\PlantografContent.contentproj    1    0    0
Solution    Plantograf.sln    0    0    1
Solution and projects
Plantograf
Message
Plantograf\Plantograf\Plantograf.csproj: The application which this project type is based on was not found. Please try this link for further information: http://go.microsoft.com/fwlink/?LinkID=299083&projecttype=6D335F3A-9D43-41b4-9D22-F6F17C4BE596
PlantografContent
Message
Plantograf\PlantografContent\PlantografContent.contentproj: The application which this project type is based on was not found. Please try this link for further information: http://go.microsoft.com/fwlink/?LinkId=659044&projecttype=96E2B04D-8817-42C6-938A-82C39BA4D311
Solution
Message
Show 1 additional messages

A GUID search 表示这是一个 C# XNA 项目。

但自 Microsoft retired XNA 起,它将不会在最新的 Visual Studio 版本中打开。您应该使用 Visual Studio 2010(但 Express 版本可能不合格)。

如果可能,请使用 MonoGame 创建一个新项目并迁移。您可以在 Google 找到一些帖子,比如

Porting of a existing XNA Windows Phone Game to Windows 8

这些解决方案有效: