public bool AddAmmu(GameManager.bulletType bullet) { if (bullet == typeOfBullet) { ammuAmount = (ammuAmount + reloadAmount) > maxAmmu ? maxAmmu : (ammuAmount + reloadAmount); UpdateAmmuGUI(); return(true); } else { return(false); } }
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); } }
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); } }
public bool AddAmmu(GameManager.bulletType type, int amount) { return(equipedWeaponScript.AddAmmu(type, amount)); }