title: How to get controller input when using the SteamVR Interaction System
body: <p>I want to just simply get controller input from the user in my VR game, and i also want to use the SteamVR interaction system so that I can have easy UI stuff be implemented. However, I cannot get input from the controller off of the Hand script. </p>
  
  <p>All that I did was drag in the "Player" prefab, and then write a script to go on the Hand object to get input from the triggers. </p>
  
  <pre><code>    private Hand _hand;                     // The hand object
      private SteamVR_Controller.Device controller; // the controller property of the hand
  
  
      void Start ()
      {
          // Get the hand componenet
          _hand = GetComponent&lt;Hand&gt;();
          // Set the controller reference
          controller = _hand.controller;
      }
  
      void Update ()
      {
              // === NULL REFERENCE === //
          if ( controller.GetHairTrigger())
          {
              Debug.Log ("Trigger");
          }
  
      }
  </code></pre>
  
  <p>This gives me a null ref exception to the "controller" object. I have also tried getting the controller component in <code>OnEnable()</code> and <code>Awake()</code> and that didn't work either. Even in <code>Update()</code>. So for some reason the <code>Hand</code> class of SteamVR does not hold a reference to the controller. Am I doing something wrong?Am I missing some sort of index specification when i get the controller? </p>
  
  <p>I am able to get controller input like this:</p>
  
  <pre><code>   private SteamVR_TrackedObject trackedObj;       // The tracked object that is the controller
  
      private SteamVR_Controller.Device Controller    // The device property that is the controller, so that we can tell what index we are on
      {
          get { return SteamVR_Controller.Input((int)trackedObj.index); }
      }
  
      private void Awake()
      {
          // Get the tracked object componenet
          trackedObj = GetComponent&lt;SteamVR_TrackedObject&gt;();
      }
  
      void Update()
   {
       if(Controller.GetHairTrigger()){
            Debug.Log("hey trigger");
       }
    }
  </code></pre>
  
  <p>But then I cannot use the Interaction system. Anyone have a clue?</p>