diff --git a/pkNX.WinForms/Subforms/GGWE.cs b/pkNX.WinForms/Subforms/GGWE.cs index 82fd3d92..0d4d0a76 100644 --- a/pkNX.WinForms/Subforms/GGWE.cs +++ b/pkNX.WinForms/Subforms/GGWE.cs @@ -367,8 +367,9 @@ private void RandomizeWild(SpeciesRandomizer rand, bool fill, bool wildMega) void ApplyRand(IList slots) { - foreach (var s in slots) + for (int i = 0; i < slots.Count; i++) { + var s = slots[i]; if (s.Species == 0) { if (!fill) @@ -378,6 +379,8 @@ void ApplyRand(IList slots) s.Species = rand.GetRandomSpecies(s.Species); s.Form = Legal.GetRandomForme(s.Species, wildMega, true, pt); + if (fill) + s.Probability = RandomScaledRates[slots.Count][i]; } } @@ -389,5 +392,13 @@ void ApplyRand(IList slots) ApplyRand(slots); } } + + public static readonly Dictionary RandomScaledRates = new Dictionary + { + [01] = new[] {100}, + [04] = new[] {60, 30, 7, 3}, + [05] = new[] {40, 30, 18, 10, 2}, + [10] = new[] {20, 15, 15, 10, 10, 10, 10, 5, 4, 1}, + }; } }