/// <summary> /// The HPs are added when Use() is called /// </summary> /// <returns> the Time that the item is in use</returns> public override int Use() { base.Use(); ItemInUse = true; Owner.AddHealth(_addHP, true); if (_net.IsServer || _net.IsClient) { Network.Destroy(gameObject); } else { Destroy(gameObject); } return(Time); }
// --------------------- BASE METHODS ------------------ // --------------------- CUSTOM METHODS ---------------- // commands public override void UsePowerup() { base.UsePowerup(); Owner.AddHealth(ValuePotion); }