fixed sounds
This commit is contained in:
@ -14,13 +14,7 @@ public class Shooting : MonoBehaviour
|
||||
private float _fireCountdown = 1f;
|
||||
|
||||
public GameObject gun;
|
||||
public AudioSource audio;
|
||||
|
||||
private void Start()
|
||||
{
|
||||
//audio = GetComponent<AudioSource>();
|
||||
//audio.Play();
|
||||
}
|
||||
public AudioSource audioSource;
|
||||
|
||||
private void Update()
|
||||
{
|
||||
@ -33,7 +27,7 @@ public class Shooting : MonoBehaviour
|
||||
{
|
||||
_fireCountdown = 0;
|
||||
_fireCountdown += hSliderValue;
|
||||
audio.Play();
|
||||
audioSource.Play();
|
||||
Shoot();
|
||||
}
|
||||
_fireCountdown -= Time.deltaTime;
|
||||
|
Reference in New Issue
Block a user