soundvision/UnityProject/Assets/AzureKinectExamples/KinectDemos/BlobDetectionDemo/Scripts/CollisionLogger.cs

19 lines
436 B
C#
Raw Normal View History

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace com.rfilkov.components
{
public class CollisionLogger : MonoBehaviour
{
private void OnTriggerEnter(Collider other)
{
if (other.GetComponent<CollisionLogger>())
return;
Debug.Log("Detected collision of " + gameObject.name + " with " + other.gameObject.name);
}
}
}