/// <summary> /// Copies the Item /// </summary> /// <returns>A copy of the item</returns> public override Item Copy() { DefenseItem item = new DefenseItem(Frame); copyAttributes(item); return(item); }
/// <summary> /// Copies all attributes of the Item into the passed in Item /// </summary> /// <param name="item">The Item to copy to</param> protected override void copyAttributes(Item item) { if (!(item is DefenseItem)) { throw new Exception("Item passed into copyAttributes does not match type!"); } base.copyAttributes(item); DefenseItem dItem = item as DefenseItem; dItem.RequirementLevel = RequirementLevel; dItem.MaxDFP = MaxDFP; dItem.MaxEVP = MaxEVP; dItem.VariableDFP = RequirementLevel; dItem.VariableEVP = VariableEVP; dItem.Slots = Slots; }