void InteractableSearch() { GameObject[] objs = GameObject.FindGameObjectsWithTag("Interactable"); foreach (GameObject obj in objs) { //Interactable inter = obj.GetComponent<Interactable>(); ItemPackage inter = obj.GetComponent <ItemPackage>(); if (inter != null) { inter.CheckInteract(body); } } }