Fix hidden power string detection

This commit is contained in:
Kurt 2015-04-01 17:20:09 -07:00
parent 9928bc1e14
commit 8f2bc04a82

View File

@ -1625,9 +1625,9 @@ public Set(string input, string[] species, string[] items, string[] natures, str
string moveString = line.Substring(2);
if (moveString.Contains("Hidden Power"))
{
if (moveString.Length > 11) // Defined Hidden Power
if (moveString.Length > 13) // Defined Hidden Power
{
string type = moveString.Remove(0, 12).Replace("[", "").Replace("]", ""); // Trim out excess data
string type = moveString.Remove(0, 13).Replace("[", "").Replace("]", ""); // Trim out excess data
int hpVal = Array.IndexOf(hptypes, type); // Get HP Type
if (hpVal >= 0) IVs = setHPIVs(hpVal, IVs); // Get IVs
}