salut tout le monde
j'ai un problème avec la case use use gravity de rigidbody voila le script
ce script sert a faire une Coroutine pour laisser les temps a mes animation de se lancer , et quand
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24 CharacterController Character; Vector3 Moovedirection = Vector3.zero; void Start () { Character = gameObject.GetComponent<CharacterController> (); StartCoroutine (maCoroutine ()); } IEnumerator maCoroutine(){ anim.Play ("Animation1"); yield return new WaitForSeconds (1.21f); anim.Play ("Animation2"); yield return new WaitForSeconds (3.07f); gameObject.GetComponent<Rigidbody> ().useGravity = true; anim.Play ("Animation3"); yield return new WaitForSeconds (4); anim.Play ("Animation4"); }pour jouer
Code : Sélectionner tout - Visualiser dans une fenêtre à part yield return new WaitForSeconds (3.07f);ca ne marche plus et mon perso ne tombe pas ?
Code : Sélectionner tout - Visualiser dans une fenêtre à part gameObject.GetComponent<Rigidbody> ().useGravity = true;
mais avant de changer de version de unity3D ca marche je ne sais pas pourquoi ?
Partager