using UnityEngine;
public class ExampleScript : MonoBehaviour { // Print out which type of Component is attached to the collider we hit void OnCollisionStay(Collision collision) { // Check if the collider your GameObject hits has a rigidbody if (collision.body as Rigidbody) { Debug.Log("Has Rigidbody."); }
// Check if the collider your GameObject hits has an articulation body if (collision.body as ArticulationBody) { Debug.Log("Has ArticulationBody."); } } }