老师,我将预制体是一个可以播放序列帧动画的image,单独打了一个包,然后将animator单独打了一个包,在后续加载的过程中,实例化到场景中的预制物体不在播放动画了。希望老师解答一下,谢谢
AssetBundle turntableAinmaCont = AssetBundle.LoadFromFile(Application.streamingAssetsPath + "/turntableanimacon"); //加载AnimatorController资源
Object tAC = turntableAinmaCont.LoadAsset("Turntable");
AssetBundle turntable = AssetBundle.LoadFromFile(Application.streamingAssetsPath + "/turntable"); //加载的预制物体资源
GameObject tb = turntable.LoadAsset<GameObject>("turntable");
Instantiate(tb); //实例化预制物体
tb.transform.SetParent(parent);
tb.GetComponent<Animator>().runtimeAnimatorController = (RuntimeAnimatorController)tAC;