using UnityEngine; public class Trigger : MonoBehaviour { public AudioSource audioSource; public GameObject audioObject; void OnTriggerEnter(Collider other) { if (other.tag == "Player" ) { audioSource.Play(); } } }