public LocalEmbedBuilder CreateInfoEmbed() { var eb = new LocalEmbedBuilder() .WithDefaultColor() .WithTitle(ToString()) .WithDescription(Summary); var displayMethods = new List <string>(); var displayProperties = new List <string>(); var propertyCount = 0; var methodCount = 0; foreach (var member in Members) { if (member is SearchableMethod method) { if (displayMethods.Count < 3 && !displayMethods.Contains(method.Info.Name)) { displayMethods.Add(method.Info.Name); } methodCount++; } else if (member is SearchableProperty property) { if (displayProperties.Count < 3 && !displayProperties.Contains(property.Info.Name)) { displayProperties.Add(property.Info.Name); } propertyCount++; } } if (displayProperties.Count > 0) { eb.AddInlineCodeBlockField($"Properties ({propertyCount})", string.Join("\n", displayProperties)); eb.AddInlineBlankField(); } if (displayMethods.Count > 0) { eb.AddInlineCodeBlockField($"Methods ({methodCount})", string.Join('\n', displayMethods)); } return(eb); }