mirror of
https://github.com/kwsch/PKHeX.git
synced 2026-05-09 04:24:36 -05:00
Add missing hax item clamp early return
Closes #2281 remove unnecessary "else", and break for visual separation
This commit is contained in:
parent
33a07a6fcd
commit
a45cddd3ed
|
|
@ -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;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user