Add missing hax item clamp early return

Closes #2281
remove unnecessary "else", and break for visual separation
This commit is contained in:
Kurt 2019-05-27 21:38:04 -07:00
parent 33a07a6fcd
commit a45cddd3ed

View File

@ -195,8 +195,10 @@ public bool IsValidItemAndCount(ITrainerInfo SAV, int itemindex, bool HasNew, bo
itemcnt = byte.MaxValue;
else if (SAV.Generation >= 3 && itemcnt > ushort.MaxValue)
itemcnt = ushort.MaxValue;
return true;
}
else if (itemcnt > MaxCount)
if (itemcnt > MaxCount)
{
if (itemindex == 797 && itemcnt >= 2) // Edge case when for some reason the item count for Z-Ring was 2 in an unedited save and set 1 after using PKHeX
itemcnt = 2;