So i am grabbing my objects in vr by making them child objects of my controller and i want to check on the object if it is being held like this:
void Update ()
{
if (transform.parent.gameObject.CompareTag("Controller"))
{
print("true");
isBeingHeld = true;
}
else if(!transform.parent.gameObject.CompareTag("Controller"))
{
isBeingHeld = false;
print("false");
}
}
but this only returns true and never gets to false