protected Mission(IDataRecord record) { id = record.GetValue <int>(k.ID.ToLower()); _missionIdOnSuccess = record.GetValue <int?>(k.missionIDOnSuccess.ToLower()); isUnique = record.GetValue <bool>(k.isUnique.ToLower()); _periodMinutes = record.GetValue <int?>(k.periodMinutes.ToLower()); _missionLevel = record.GetValue <int?>(k.missionLevel.ToLower()); title = record.GetValue <string>(k.title); _description = record.GetValue <string>(k.description); _missionType = record.GetValue <int>(k.missionType.ToLower()); durationMinutes = record.GetValue <int>(k.durationMinutes.ToLower()); _successMessage = record.GetValue <string>(k.successMessage.ToLower()); failMessage = record.GetValue <string>(k.failMessage.ToLower()); listable = record.GetValue <bool>(k.listable); rewardFee = record.GetValue <double>(k.rewardFee.ToLower()); _locationId = record.GetValue <int?>("locationid"); behaviourType = (MissionBehaviourType)record.GetValue <int>("behaviourtype"); _difficultyReward = record.GetValue <int?>("difficultyreward"); _difficultymultiplier = record.GetValue <double?>("difficultymultiplier"); missionCategory = MissionDataCache.GetMissionCategoryByType(_missionType); InitIssuer(record); _myTargets = new Lazy <List <MissionTarget> >(CollectMyTargets); _myDictionary = new Lazy <Dictionary <string, object> >(GenerateMyDictionary); }