private void OnValidate()
 {
     if (InputManager.Exists)
     {
         m_cachedInputAction = InputManager.GetAction(m_schemeName, m_actionName);
     }
 }
예제 #2
0
                #pragma warning restore 0649

        public InputAction Get()
        {
            if (m_cachedInputAction == null && InputManager.Exists)
            {
                m_cachedInputAction = InputManager.GetAction(m_schemeName, m_actionName);
            }

            return(m_cachedInputAction);
        }
예제 #3
0
        public InputBinding Get()
        {
            if (m_cachedInputBinding == null && InputManager.Exists)
            {
                var action = InputManager.GetAction(m_schemeName, m_actionName);
                if (action != null)
                {
                    m_cachedInputBinding = action.GetBinding(m_bindingIndex);
                }
            }

            return(m_cachedInputBinding);
        }
예제 #4
0
 private void OnValidate()
 {
     if (InputManager.Exists)
     {
         var action = InputManager.GetAction(m_schemeName, m_actionName);
         if (action != null)
         {
             m_cachedInputBinding = action.GetBinding(m_bindingIndex);
         }
         else
         {
             m_cachedInputBinding = null;
         }
     }
 }