public VehicleEquipModel(int id) : base(id) { var row = GetVehicleEquipRow(); PartType = row.PartType; Attack = row.Attack; Defence = row.Defence; RangeType = row.RangeType; Magazine = row.Magazine; Weight = row.Weight; Load = row.Load; MaxDefence = row.MaxDefence; MaxMagazine = row.MaxMagazine; MaxWeight = row.MaxWeight; MainHole = row.MainHole; SubHole = row.SubHole; SEHole = row.SEHole; MainGunLocation = row.MainGunLocation; SubGunLocation = row.SubGunLocation; SEGunLocation = row.SEGunLocation; CanTrans = row.CanTrans; TransPrice = row.TransPrice; TransId = row.TransId; }
public List <VehiclePart> GetVehicleParts(VehiclePartType partType) { var parts = Parts.Where(o => o.Type == partType); return(parts.ToList()); }
public VehiclePart GetVehiclePart(VehiclePartType partType) { var part = Parts.Where(o => o.Type == partType).FirstOrDefault(); return(part); }