public bool addPotion(Potion p) { if(p.getWeight() + weight > weightLimit) { return false; } else { potions.Add(p); weight += p.getWeight(); return true; } }
public bool addPotion(Potion p) { if(p.getWeight() + weight > weightLimit) { return false; } else { potions.Add(p); weight += p.getWeight(); return true; } }