2018版的unity,导出pc端,但是导出时报错。
导出报错的第一个错误
DirectoryNotFoundException: Could not find a part of the path "D:\unity\消防\Assets\�ű�\NewEditorScript1.cs".
System.IO.FileStream..ctor (System.String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, Boolean anonymous, FileOptions options) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.IO/FileStream.cs:292)
System.IO.FileStream..ctor (System.String path, FileMode mode, FileAccess access, FileShare share)
(wrapper remoting-invoke-with-check) System.IO.FileStream:.ctor (string,System.IO.FileMode,System.IO.FileAccess,System.IO.FileShare)
System.IO.File.Open (System.String path, FileMode mode, FileAccess access, FileShare share) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.IO/File.cs:358)
UnityEditor.Scripting.APIUpdaterHelper.FindTypeMatchingMovedTypeBasedOnNamespaceFromError (IEnumerable`1 lines) (at D:/unity/Editor/Mono/Scripting/APIUpdaterHelper.cs:305)
UnityEditor.Scripting.APIUpdaterHelper.IsReferenceToTypeWithChangedNamespace (System.String normalizedErrorMessage) (at D:/unity/Editor/Mono/Scripting/APIUpdaterHelper.cs:48)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)
先说一下,你是第一次用,对电脑懂不懂?
感觉像是中文路径导致的。不要用中文路径试试看哦!
中文其实是支持的,不过你这确实是乱码了,可能和编码格式有关吧,先改成英文;另外代码里还有弃用的方法和类,你要按照提示进行替换
不是路径的问题,是脚本的问题,你脚本是怎么写的,缺少某个命名空间或者类对象,还有不包含某个类,另外继承Editor的类要放在Editor文件夹下