Fix Showdown Imports for Nidoran (#1886)

Showdown Set isn't recognized because of the format `Nidoran-G (G)` where G is M/F
This commit is contained in:
Archit Date
2018-04-05 09:30:54 +08:00
committed by Kurt
parent bdb6b7a2f1
commit d65652a34e

View File

@@ -281,10 +281,10 @@ private bool ParseSpeciesForm(string spec)
return true;
// failure to parse, check edge cases
var edge = new[] {784, 250}; // all species with dashes in English Name (Kommo-o & Ho-Oh)
var edge = new[] {784, 250, 032, 029}; // all species with dashes in English Name (Kommo-o, Ho-Oh, Nidoran-M, Nidoran-F)
foreach (var e in edge)
{
if (!spec.StartsWith(species[e]))
if (!spec.StartsWith(species[e].Replace("♂", "-M").Replace("♀", "-F")))
continue;
Species = e;
Form = spec.Substring(species[e].Length);