-1

将 GoogleVR for Unity 资产导入最新版本的 Unity 后,我会立即收到以下编译错误:

Assets/GoogleVR/Scripts/Controller/Internal/Emulator/EmulatorClientSocket.cs(74,46): error CS0120: An object reference is required to access non-static member `System.Diagnostics.Process.Start()'

Assets/GoogleVR/Scripts/Controller/Internal/Emulator/EmulatorClientSocket.cs(79,17): error CS1061: Type `System.Diagnostics.Process' does not contain a definition for `Close' and no extension method `Close' of type `System.Diagnostics.Process' could be found (are you missing a using directive or an assembly reference?)

这发生在一个使用最新版本的 GoogleVR 和 Unity for OSX 的完全空项目上。有没有其他人看过这个?

4

2 回答 2

0

将 Unity 更新到 5.4.0B20(最新的 Beta 版本),它就可以正常工作了。在 Unity 论坛上找到了该解决方案,但现在找不到在哪里。

于 2016-06-08T21:30:20.103 回答
0

这是因为在某些版本的 Unity 中,默认平台是 WebGL。您可以通过在 File | 中切换到 Android 平台来解决此问题。构建设置。

您可以通过 File -> Build Setting -> 选择 Android 并点击 Switch Platform 来切换平台

于 2016-06-29T03:35:35.697 回答