Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Question TryGetFeatureValue Polling Too Many Inputs

Discussion in 'XR Interaction Toolkit and Input' started by nawc_tg, Nov 17, 2021.

  1. nawc_tg

    nawc_tg

    Joined:
    Oct 2, 2019
    Posts:
    3
    I'm using Vive controllers and using the XR Input mapping in an Update(). The polling seems too fast because I am receiving multiple inputs when pressing buttons ( gripButton, trigger, primary2DAxisClick, etc ).

    I'm using Unity 2021.1.27f1
     
  2. C-Through

    C-Through

    Joined:
    Aug 18, 2016
    Posts:
    4
    TryGetFeature doesn't support up/down press events. Instead, it just gets the value. You can write additional logic for this, but TryGetGeature is a deprecated system and prevents you from using newer packages like OpenXR. Instead, you can look into Unity's New Input System and OpenXR if you're looking to get more input functionality without writing it yourself.
     
    nawc_tg likes this.