This repository has been archived on 2026-04-30. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
monsterstalker/Assets/Scripts/SoundController.cs
T
2018-04-11 16:54:57 +10:00

17 lines
330 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class SoundController : MonoBehaviour {
AudioSource audioSource;
public AudioClip snapShot;
void Awake() {
audioSource = GetComponent<AudioSource> ();
}
public void PlaySnapShot() {
audioSource.PlayOneShot (snapShot, 1.0f);
}
}