Misc fixes

This commit is contained in:
Kurt 2024-11-10 19:22:59 -06:00
parent de57e197ad
commit 8b09d9467d
2 changed files with 2 additions and 2 deletions

View file

@ -364,7 +364,7 @@ public sealed class EncounterGift3 : IEncounterable, IEncounterMatch, IMoveset,
return Method switch return Method switch
{ {
BACD_U => type is BACD_U, BACD_U => type is BACD,
BACD_R => IsRestrictedSimple(ref value, type), BACD_R => IsRestrictedSimple(ref value, type),
BACD_R_A => IsRestrictedAnti(ref value, type), BACD_R_A => IsRestrictedAnti(ref value, type),
BACD_U_AX => IsUnrestrictedAntiX(ref value, type), BACD_U_AX => IsUnrestrictedAntiX(ref value, type),

View file

@ -214,7 +214,7 @@ public static class CommonEvent3
public static uint GetGenderBit0(uint rand16) => (rand16 / 3) & 1; public static uint GetGenderBit0(uint rand16) => (rand16 / 3) & 1;
public static uint GetGenderBit3(uint rand16) => (rand16 >> 3) & 1; public static uint GetGenderBit3(uint rand16) => (rand16 >> 3) & 1;
public static uint GetGenderBit7(uint rand16) => (rand16 >> 7) & 1; public static uint GetGenderBit7(uint rand16) => ((rand16 >> 7) & 1) ^ 1; // Returns Female (1) when calc is 0
public static uint GetGenderBit15(uint rand16) => (rand16 >> 15) & 1; public static uint GetGenderBit15(uint rand16) => (rand16 >> 15) & 1;
public static uint GetGenderBit0(ref uint seed) => GetGenderBit0(LCRNG.Next16(ref seed)); public static uint GetGenderBit0(ref uint seed) => GetGenderBit0(LCRNG.Next16(ref seed));
public static uint GetGenderBit3(ref uint seed) => GetGenderBit3(LCRNG.Next16(ref seed)); public static uint GetGenderBit3(ref uint seed) => GetGenderBit3(LCRNG.Next16(ref seed));