16 lines
370 B
C#
16 lines
370 B
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
|
|
[RequireComponent(typeof(BoxCollider))]
|
|
[RequireComponent(typeof(UIEventTrigger))]
|
|
public class PlaySelectClickSound : MonoBehaviour
|
|
{
|
|
public AudioClip m_Clip;
|
|
float m_Volume = 0.5f;
|
|
|
|
void OnClick()
|
|
{
|
|
if (m_Clip) SoundInfo.Ins.Play_OneShot(m_Clip, m_Volume);
|
|
}
|
|
} |