private void Update()
{
SetHealthAmount(player.GetHealthPct());
if (!weaponManager.isReloading)
{
SetAmmoAmount(weaponManager.GetCurrentWeapon().bullets, weaponManager.GetCurrentWeapon().maxBullets);
}
else
{
SetAmmoAmount(0, weaponManager.GetCurrentWeapon().maxBullets);
}
if (Input.GetKeyDown(KeyCode.Tab))
{
scoreboard.SetActive(true);
}
else if (Input.GetKeyUp(KeyCode.Tab))
{
scoreboard.SetActive(false);
}
if (Input.GetKeyDown(KeyCode.R) && !weaponManager.isReloading)
{
weaponManager.Reload();
}
}