你可以这样

 Animator animator = this.gameObject.GetComponent<Animator>();
 animator.runtimeAnimatorController = Resources.Load("path_to_your_controller") as RuntimeAnimatorController;

也可以这样

public RuntimeAnimatorController anim2;
this.GetComponent().runtimeAnimatorController = anim2 as RuntimeAnimatorController;

 

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-01-15
  • 2021-09-27
  • 2021-11-08
  • 2021-11-03
  • 2022-12-23
猜你喜欢
  • 2021-06-25
  • 2021-12-16
  • 2022-12-23
  • 2021-11-29
  • 2022-03-10
  • 2021-09-03
  • 2022-01-17
相关资源
相似解决方案