| | |
| | | var animator = model.GetComponent<Animator>();
|
| | | if (animator != null)
|
| | | {
|
| | | //ResetRealmBossAnimator(id, animator);
|
| | | ResetRealmBossAnimator(id, animator);
|
| | | animator.enabled = false;
|
| | | }
|
| | |
|
| | |
| | | }
|
| | | }
|
| | |
|
| | | //private static void ResetRealmBossAnimator(int _id, Animator animator)
|
| | | //{
|
| | | // var configs = RealmConfig.GetValues();
|
| | | // var index = configs.FindIndex((x) =>
|
| | | // {
|
| | | // return x.BossID == _id;
|
| | | // });
|
| | | // if (index != -1)
|
| | | // {
|
| | | // var npcConfig = NPCConfig.Get(_id);
|
| | | // if (npcConfig != null)
|
| | | // {
|
| | | // var runtimeController = AnimatorControllerLoader.LoadMobController(AnimatorControllerLoader.controllerSuffix, npcConfig.MODE);
|
| | | // if (runtimeController != null)
|
| | | // {
|
| | | // animator.runtimeAnimatorController = runtimeController;
|
| | | // }
|
| | | // }
|
| | | // }
|
| | | //}
|
| | | private static void ResetRealmBossAnimator(int _id, Animator animator)
|
| | | {
|
| | | if (RealmLVUPTaskConfig.IsRealmBoss(_id))
|
| | | {
|
| | | var npcConfig = NPCConfig.Get(_id);
|
| | | if (npcConfig != null)
|
| | | {
|
| | | var runtimeController = AnimatorControllerLoader.LoadMobController(AnimatorControllerLoader.controllerSuffix, npcConfig.MODE);
|
| | | if (runtimeController != null)
|
| | | {
|
| | | animator.runtimeAnimatorController = runtimeController;
|
| | | }
|
| | | }
|
| | | }
|
| | | }
|
| | |
|
| | | public static GameObject LoadUIHorse(int id)
|
| | | {
|