// Use this for initialization void Start() { attachedTo = GetComponent <AudioSource>(); Manager = HDRController.AudioManager; if (Manager != null) { Manager.AddAudioSource(this); } else { Debug.LogError("HDR Audio Manager not found : " + name + " a " + transform.position); } }
void Awake() { AudioManager = this; }