mirror of
https://github.com/kwsch/PKHeX
synced 2024-11-24 21:13:05 +00:00
Gen3 PCNY: remove OT gender checks
Same as PCJP, uses the recipient's save file gender. Not random.
This commit is contained in:
parent
4414b34fe7
commit
52437d1712
1 changed files with 0 additions and 9 deletions
|
@ -87,7 +87,6 @@ public sealed class EncounterGift3NY(ushort Species, Distribution3NY Distributio
|
|||
pk.PID = pid;
|
||||
pk.IV32 = PIDGenerator.SetIVsFromSeedSequentialLCRNG(ref seed);
|
||||
pk.RefreshAbility((int)(pid & 1));
|
||||
pk.OriginalTrainerGender = (byte)GetGender(LCRNG.Next16(ref seed));
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -168,14 +167,6 @@ public sealed class EncounterGift3NY(ushort Species, Distribution3NY Distributio
|
|||
if (type is not PIDType.BACD_AX)
|
||||
return false;
|
||||
|
||||
var seed = value.OriginSeed;
|
||||
var rand5 = LCRNG.Next5(seed) >> 16;
|
||||
var expect = GetGender(rand5);
|
||||
if (pk.OriginalTrainerGender != expect)
|
||||
return false;
|
||||
|
||||
return true; // Table weight -> gift selection is a separate RNG, nothing to check!
|
||||
}
|
||||
|
||||
private static uint GetGender(uint rand16) => CommonEvent3.GetGenderBit7(rand16);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue