Airconsole 和 Unity 集成问题
Airconsole & Unity integration issue
首先,我是 unity 和 airconsole 这两个平台的新手。
我只是在探索与 airconsole 集成的统一性,但我在导入 "airconsole plugin"(从 Asset Store
导入)时遇到错误。
我在 windows 10.
上使用最新版本的 unity 2018.3.0f2 Personal
以下是我在统一控制台中看到的一些错误消息
Assets\AirConsole\plugins\Newtonsoft.Json\Utilities\DynamicWrapper.cs(27,20): error CS0246: The type or namespace name 'ModuleBuilder' could not be found (are you missing a using directive or an assembly reference?)
Assets\AirConsole\plugins\Newtonsoft.Json\Utilities\DynamicWrapper.cs(25,20): error CS0246: The type or namespace name 'ModuleBuilder' could not be found (are you missing a using directive or an assembly reference?)
Assets\AirConsole\plugins\Newtonsoft.Json\Utilities\DynamicReflectionDelegateFactory.cs(193,72): error CS0246: The type or namespace name 'ILGenerator' could not be found (are you missing a using directive or an assembly reference?)
Assets\AirConsole\plugins\Newtonsoft.Json\Utilities\DynamicReflectionDelegateFactory.cs(214,81): error CS0246: The type or namespace name 'ILGenerator' could not be found (are you missing a using directive or an assembly reference?)
...........
我该如何解决问题并测试基本的 airconsole 示例。
提前致谢:)
AirConsole官方支持的最后一个版本是2018.2.11
(见"supported versions"下的asset storedownload page),看你是运行2018.3.x
这个可能会导致版本控制错误。
在 Unity 中导入资产 2017.3.0
没有产生任何错误,因此降级到官方支持的最新版本应该可以解决问题。
但是如果您想坚持使用 Unity 2018.3
您将不得不等待开发人员的支持,或者您可以尝试将您的 Newtonsoft.Json 库更新到最新版本。
要更新,您需要使用 NuGet 包管理器中的 PM> Install-Package Newtonsoft.Json -Version 12.0.1
下载 Newtonsoft.Json
with NuGet,并覆盖 Assets\AirConsole\Plugins 中的版本。 NuGet page.
更新 Newtonsoft 版本消除了您在 2018.3
中发布的错误,但我尚未对其进行彻底测试,因此不能保证它会 100% 正常工作。
无需更新 Newtonsoft.Json 库。相反,您可以简单地将 API Compatibility Level
设置为 Player Settings / WebGL Settings / Other Settings
中的 .NET 4.x
。
为了解决这些错误,需要将平台(在构建设置中)设置为 WebGL
,或者您还必须更改 API 中当前所选平台的兼容性级别它自己的 Player Settings
首先,我是 unity 和 airconsole 这两个平台的新手。
我只是在探索与 airconsole 集成的统一性,但我在导入 "airconsole plugin"(从 Asset Store
导入)时遇到错误。
我在 windows 10.
上使用最新版本的 unity2018.3.0f2 Personal
以下是我在统一控制台中看到的一些错误消息
Assets\AirConsole\plugins\Newtonsoft.Json\Utilities\DynamicWrapper.cs(27,20): error CS0246: The type or namespace name 'ModuleBuilder' could not be found (are you missing a using directive or an assembly reference?)
Assets\AirConsole\plugins\Newtonsoft.Json\Utilities\DynamicWrapper.cs(25,20): error CS0246: The type or namespace name 'ModuleBuilder' could not be found (are you missing a using directive or an assembly reference?)
Assets\AirConsole\plugins\Newtonsoft.Json\Utilities\DynamicReflectionDelegateFactory.cs(193,72): error CS0246: The type or namespace name 'ILGenerator' could not be found (are you missing a using directive or an assembly reference?)
Assets\AirConsole\plugins\Newtonsoft.Json\Utilities\DynamicReflectionDelegateFactory.cs(214,81): error CS0246: The type or namespace name 'ILGenerator' could not be found (are you missing a using directive or an assembly reference?)
...........
我该如何解决问题并测试基本的 airconsole 示例。 提前致谢:)
AirConsole官方支持的最后一个版本是2018.2.11
(见"supported versions"下的asset storedownload page),看你是运行2018.3.x
这个可能会导致版本控制错误。
在 Unity 中导入资产 2017.3.0
没有产生任何错误,因此降级到官方支持的最新版本应该可以解决问题。
但是如果您想坚持使用 Unity 2018.3
您将不得不等待开发人员的支持,或者您可以尝试将您的 Newtonsoft.Json 库更新到最新版本。
要更新,您需要使用 NuGet 包管理器中的 PM> Install-Package Newtonsoft.Json -Version 12.0.1
下载 Newtonsoft.Json
with NuGet,并覆盖 Assets\AirConsole\Plugins 中的版本。 NuGet page.
更新 Newtonsoft 版本消除了您在 2018.3
中发布的错误,但我尚未对其进行彻底测试,因此不能保证它会 100% 正常工作。
无需更新 Newtonsoft.Json 库。相反,您可以简单地将 API Compatibility Level
设置为 Player Settings / WebGL Settings / Other Settings
中的 .NET 4.x
。
为了解决这些错误,需要将平台(在构建设置中)设置为 WebGL
,或者您还必须更改 API 中当前所选平台的兼容性级别它自己的 Player Settings