加载asset bundle的时候出现Could not produce class with ID XXX的错误
在asset 文件夹下建一个Link的XML,内容如下:
<?xml version="1.0" encoding="utf-8"?>
<linker>
<assembly fullname="UnityEngine">
<type fullname="UnityEngine.SphereCollider" preserve="all"/>
<type fullname="UnityEngine.AudioSources" preserve="all"/>
<type fullname="UnityEngine.ReflectionProbe" preserve="all"/>
<type fullname="UnityEngine.Avatar" preserve="all"/>
<type fullname="UnityEngine.Animator" preserve="all"/>
<type fullname="UnityEngine.PhysicMaterial" preserve="all"/>
<type fullname="UnityEngine.CapsuleCollider" preserve="all"/>
</assembly>
<assembly fullname="System">
<type fullname="System.Exception" preserve="all"/>
</assembly>
</linker>
在这个网站https://docs.unity3d.com/Manual/ClassIDReference.htm上l根据ClassID找到对应的脚本