Exemple #1
0
    public IEnumerator Shoot()
    {
        if (ammoSlot.CurrentAmountAmmo(ammoType) > 0 && canShoot == true)
        {
            PlayMuzzleFX();
            ProcessRaycast();
            ammoSlot.AmmoDecrease(ammoType);
            canShoot = false;
            yield return(new WaitForSeconds(shootTimer));

            canShoot = true;
        }
    }
Exemple #2
0
 void Start()
 {
     amountAmmunitionText.text = ammoSlot.CurrentAmountAmmo(ammoType).ToString();
     WeaponZoom.zoomedInToggle = true;
     SetActiveWeapon();
 }