Exemplo n.º 1
0
 public bool AddAmmu(GameManager.bulletType bullet)
 {
     if (bullet == typeOfBullet)
     {
         ammuAmount = (ammuAmount + reloadAmount) > maxAmmu ? maxAmmu : (ammuAmount + reloadAmount);
         UpdateAmmuGUI();
         return(true);
     }
     else
     {
         return(false);
     }
 }
Exemplo n.º 2
0
    public bool AddAmmu(GameManager.bulletType type)
    {
        bool reloaded = equipedWeaponScript.AddAmmu(type);

        if (reloaded)
        {
            return(true);
        }
        else
        {
            reloaded = secondWeapon.GetComponent <Weapon>().AddSecondAmmu(type);
            //equipedWeaponScript.UpdateAmmuGUI(secondWeaponText);
            return(reloaded);
        }
    }
Exemplo n.º 3
0
 public bool AddSecondAmmu(GameManager.bulletType bullet)
 {
     if (bullet == typeOfBullet)
     {
         if (guiCanvas == null)
         {
             Start();
         }
         ammuAmount = (ammuAmount + reloadAmount) > maxAmmu ? maxAmmu : (ammuAmount + reloadAmount);
         Player.player.secondWeaponText.text = ammuAmount.ToString();
         return(true);
     }
     else
     {
         return(false);
     }
 }
Exemplo n.º 4
0
 public bool AddAmmu(GameManager.bulletType type, int amount)
 {
     return(equipedWeaponScript.AddAmmu(type, amount));
 }