public GetGunSound ( int index ) : |
||
index | int | |
return |
// Use this for initialization void Start() { _ammoCount = 6; _firing = false; _reloading = false; _reloadTimer = 1; gunBarrelAnimator.enabled = false; //We start by spawning 6 bullets in. _bulletsArrayNav = 6; SpawnBullets(); //Then we only want 0 to spawn. _bulletsArrayNav = 0; _soundManager = GameObject.Find ("SoundManager").GetComponent<SoundManager> (); gunShot.clip = _soundManager.GetGunSound(0); }
// Use this for initialization void Start() { GunAnimator.SetInteger("Shot", 0); _equippedAnimator = GetComponent<Animator>(); _soundManager = GameObject.Find ("SoundManager").GetComponent<SoundManager> (); gunSound.clip = _soundManager.GetGunSound(0); _ammoCountHud = GameObject.Find("AmmoCount").GetComponent<Text>(); updateAmmoCountHud(); EventManager.AddListener((int) GameManagerScript.GameEvents.LoadlastCheckpoint, OnLoadLastCheckpoint); }