Exemple #1
0
 public void Shoot()
 {
     if (CurrentWeapon.Ammunition > 0)
     {
         CurrentWeapon.Fire(1);
         PlayerShotOrСhange?.Invoke();
     }
 }
Exemple #2
0
    public void WeaponSelection(int weaponNumber)
    {
        _playerAnimation.HandState = _weapons[weaponNumber].HandState;

        CurrentWeapon.gameObject.SetActive(false);
        CurrentWeapon = _weapons[weaponNumber];
        CurrentWeapon.gameObject.SetActive(true);

        PlayerShotOrСhange?.Invoke();
    }