void Start() { sesion.setStartTime(Time.time); sesion.setAyudante(null); sesion.setMascota(null); sesion.resetKeys(); }
public void seleccionMascota() { if (button_pressed != null) { animator = button_pressed.GetComponent <Animator>(); animator.ResetTrigger("select"); animator.SetTrigger("unselect"); } button_pressed = EventSystem.current.currentSelectedGameObject; animator = button_pressed.GetComponent <Animator>(); animator.runtimeAnimatorController = Resources.Load("Animaciones/Mascota") as RuntimeAnimatorController; animator.SetTrigger("select"); string mascota_select = EventSystem.current.currentSelectedGameObject.name; sesion.setMascota(mascota_select); }