gpt4 book ai didi

Unity3d 项目使 VSCode 崩溃

转载 作者:行者123 更新时间:2023-12-02 03:21:09 25 4
gpt4 key购买 nike

中型 Unity3d 项目。在 OS X 上的 VSCode 中打开正常,在 Windows 上的 VSCode 中打开它会导致深度卡住(和崩溃)。

到目前为止我发现了什么:Unity3d 使用目标 .Net 框架“v2.0”创建 .csproj 文件。目标在开发环境之间持续存在。OmniSharp 记录了很多警告,例如:

[WARNING:OmniSharp.MSBuild.MSBuildProjectSystem] The primary reference "System.Xml.Linq" could not be resolved because it has an indirect dependency on the framework assembly "System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" which could not be resolved in the currently targeted framework. ".NETFramework,Version=v2.0". To resolve this problem, either remove the reference "System.Xml.Linq" or retarget your application to a framework version which contains "System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089".

在 .csproj 文件中手动将目标框架切换到“v3.5”可以解决警告并避免 VSCode 卡住,但是只要我将新文件添加到项目 Unity 就会重新生成 .csproj 文件。

知道为什么它可以在 Mac 上运行,但拒绝在 Windows 上运行(未经修改)吗?

最佳答案

解决了。原来是集成插件将目标框架从 Unity 的默认(和工作)“v3.5”切换到“v2.0”。

已提交拉取请求:)

关于Unity3d 项目使 VSCode 崩溃,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33307399/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com