protected void ResetDisabledImplantRecipes(CustomPawn pawn) { disabledImplantRecipes.Clear(); OptionsHealth healthOptions = PrepareCarefully.Instance.Providers.Health.GetOptions(pawn); foreach (RecipeDef recipeDef in healthOptions.ImplantRecipes) { if (recipeDef.appliedOnFixedBodyParts != null) { if (recipeDef.appliedOnFixedBodyParts.Count == 1) { foreach (var uniquePart in healthOptions.FindBodyPartsForDef(recipeDef.appliedOnFixedBodyParts[0])) { if (pawn.HasSameImplant(uniquePart.Record, recipeDef)) { disabledImplantRecipes.Add(recipeDef); break; } if (pawn.HasPartBeenReplaced(uniquePart.Record)) { disabledImplantRecipes.Add(recipeDef); break; } } } } } }