其他分享
首页 > 其他分享> > Unity引用外部DLL后打包发布需要注意的一些问题

Unity引用外部DLL后打包发布需要注意的一些问题

作者:互联网

错误信息:ArgumentException: The Assembly UnityEditor is referenced by Tool ('Assets/Tools/JSBase/DLL/Tool.dll'). But the dll is not allowed to be included or could not be found.

原因:封装DLL的时候用到了UnityEditor.dll,但是在项目打包的时候,用到UnityEditor.dll的部分应放在Assets下的Editor文件中。

解决方法:1.将使用UnityEditor.dll的代码单独封装成一个dll放在Assets下的Editor。2.将代码中引用unityEditor.dll的代码单独提取出来,不封装放入Editor下。

 

错误原因:对应unity版本没有安装IL2cpp模块,在unityHub中选择添加模块,然后安装IL2CPP。

标签:UnityEditor,封装,Assets,dll,Unity,Editor,DLL,打包
来源: https://blog.csdn.net/zhaihao1996/article/details/112956751