Пример #1
0
 void Update()
 {
     if (EventSystem.current.currentSelectedGameObject == gameObject)
     {
         if (InputMapper.InteractionButton())
         {
             button.onClick.Invoke();
         }
     }
 }
Пример #2
0
 private void Update()
 {
     if (continueTimer > 0.2f && InputMapper.InteractionButton())
     {
         callback?.Invoke(0);
     }
     else if (continueTimer <= 0.2f)
     {
         continueTimer += Time.unscaledDeltaTime;
     }
 }