ButtonAudio.cs 328 B

1234567891011121314151617181920
  1. using UnityEngine;
  2. using UnityEngine.UI;
  3. using System.Collections;
  4. public class ButtonAudio : MonoBehaviour {
  5. private string mPath = "SE001";
  6. public void Start()
  7. {
  8. Button button = this.gameObject.GetComponent<Button>();
  9. if(button!= null)
  10. {
  11. button.onClick.AddListener(Play);
  12. }
  13. }
  14. public void Play(){
  15. }
  16. }