Skip to content

Commit

Permalink
tweak/fix of wrong displayed top stats in rare cases
Browse files Browse the repository at this point in the history
  • Loading branch information
cadon committed Feb 3, 2025
1 parent d9bebe1 commit f796f4f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion ARKBreedingStats/Form1.library.cs
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,8 @@ private void CalculateTopStats(List<Creature> creatures, Species onlySpecies = n
var species = g.Key;
if (species == null)
continue;
var speciesCreatures = g.ToArray();
var speciesCreatures = g.Where(c => !c.flags.HasFlag(CreatureFlags.Placeholder)).ToArray();
if (!speciesCreatures.Any()) continue;

var usedStatIndices = new List<int>(8);
var usedAndConsideredStatIndices = new List<int>();
Expand Down
2 changes: 1 addition & 1 deletion ARKBreedingStats/library/LevelStatusFlags.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public static void DetermineLevelStatus(Species species, TopLevels topLevels,
out List<string> topStatsText, out List<string> newTopStatsText)
{
// if there are no creatures of the species yet, assume 0 levels to be the current best and worst
if (topLevels == null) topLevels = new TopLevels(true);
if (topLevels == null) topLevels = new TopLevels();
var highSpeciesLevels = topLevels.WildLevelsHighest;
var lowSpeciesLevels = topLevels.WildLevelsLowest;
var highSpeciesMutationLevels = topLevels.MutationLevelsHighest;
Expand Down

0 comments on commit f796f4f

Please sign in to comment.