void Update() { if (Input.GetMouseButtonDown(0)) { if (portrait.IsPlaying("Idle")) { portrait.StopAll(0.3f); } else { portrait.CrossFade("Idle", 0.3f); } } }
void Update() { if (Input.GetMouseButtonDown(0)) { if (!isPlaying) { portrait.CrossFade("Idle", 0.3f); isPlaying = true; } else { portrait.StopAll(0.3f); isPlaying = false; } } }