From 99a1af2cb08a7008e25d7b4fe30c4a6bfec2efea Mon Sep 17 00:00:00 2001 From: Anthony Purchase Date: Wed, 14 Nov 2018 15:45:03 +0000 Subject: [PATCH] Reinstate alphatical ordering of species --- LarkatorGUI/ArkReader.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/LarkatorGUI/ArkReader.cs b/LarkatorGUI/ArkReader.cs index bfd4826..4640904 100644 --- a/LarkatorGUI/ArkReader.cs +++ b/LarkatorGUI/ArkReader.cs @@ -91,16 +91,16 @@ public async Task PerformConversion(string saveFile) .ToList(); var tameObjects = creatureObjects.Where(o => !o.IsWild()).GroupBy(o => SpeciesName(o.ClassString)); - TamedSpecies.AddRange(tameObjects.Select(o => o.Key).Distinct()); + TamedSpecies.AddRange(tameObjects.Select(o => o.Key).Distinct().OrderBy(name => name)); foreach (var group in tameObjects) TamedDinos.Add(group.Key, group.Select(o => ConvertCreature(o)).ToList()); var wildObjects = creatureObjects.Where(o => o.IsWild()).GroupBy(o => SpeciesName(o.ClassString)); - WildSpecies.AddRange(wildObjects.Select(o => o.Key).Distinct()); + WildSpecies.AddRange(wildObjects.Select(o => o.Key).Distinct().OrderBy(name => name)); foreach (var group in wildObjects) WildDinos.Add(group.Key, group.Select(o => ConvertCreature(o)).ToList()); - AllSpecies.AddRange(creatureObjects.Select(o => SpeciesName(o.ClassString)).Distinct()); + AllSpecies.AddRange(creatureObjects.Select(o => SpeciesName(o.ClassString)).Distinct().OrderBy(name => name)); } private string SpeciesName(string className)