Unity XR Input is weird

I’m new not only to Unity but the XR toolkit. Is there an XR equivalent of Unity’s Input.GetButtonDown(). Right now I’m using targetDevice.TryGetFeatureValue(UnityEngine.XR.CommonUsages.primaryButton, out pressed) && pressed) and, when I hold it the bool goes back and forth… Here’s what I what my code looks like right now.

if (red == true && targetDevice.TryGetFeatureValue(UnityEngine.XR.CommonUsages.primaryButton, out pressed) && pressed)
        {
                Debug.Log("Red Value: " + red);
                red = false;
        }
else if (red == false && targetDevice.TryGetFeatureValue(UnityEngine.XR.CommonUsages.primaryButton, out pressed) && pressed)
        {
                Debug.Log("Red Value: " + red);
                red = true;
        }

Are you using OpenXR? If so using the new input system is the way to go.

https://docs.unity3d.com/Packages/com.unity.xr.openxr@0.1/manual/input.html

Sadly I made this project In 2019.3.10f1… Is OpenXR that useful that I should remake it in 2020.3?

That is a decision you would need to make. In 2020.3+ OpenXR is how you would provide support for SteamVR and Windows Mixed reality. Oculus also recently announced they a deprecating the Oculus Provider and switching over to OpenXR eventually as well. It is mostly a matter of how close to the trend line you want your project to be.