From 50dfa3603ecf87de72d7799f641d83ee59bcc324 Mon Sep 17 00:00:00 2001 From: Kurt Date: Sat, 7 Oct 2017 20:42:51 -0700 Subject: [PATCH] fix 50/50% male/female gen1/2 7 ATKIV ma boi nixhex with wrong info at smogon http://www.smogon.com/ingame/guides/rby_gsc_stats#gender bulbapedia is right https://bulbapedia.bulbagarden.net/wiki/Individual_values#Gender Thanks StarFisherX for bringing this to my attention! --- PKHeX.Core/PKM/PK1.cs | 7 ++----- PKHeX.Core/PKM/PK2.cs | 28 ++-------------------------- 2 files changed, 4 insertions(+), 31 deletions(-) diff --git a/PKHeX.Core/PKM/PK1.cs b/PKHeX.Core/PKM/PK1.cs index ddcf620e7..c5c41b9fe 100644 --- a/PKHeX.Core/PKM/PK1.cs +++ b/PKHeX.Core/PKM/PK1.cs @@ -226,10 +226,7 @@ namespace PKHeX.Core } #region Future, Unused Attributes - public override bool IsGenderValid() - { - return true; - } + public override bool IsGenderValid() => true; // not a separate property, derived via IVs public override uint EncryptionConstant { get => 0; set { } } public override uint PID { get => 0; set { } } public override int Met_Level { get => 0; set { } } @@ -287,7 +284,7 @@ namespace PKHeX.Core case 63: return IV_ATK >= 5 ? 0 : 1; case 127: - return IV_ATK >= 7 ? 0 : 1; + return IV_ATK >= 8 ? 0 : 1; case 191: return IV_ATK >= 12 ? 0 : 1; } diff --git a/PKHeX.Core/PKM/PK2.cs b/PKHeX.Core/PKM/PK2.cs index a96719fa1..db7908840 100644 --- a/PKHeX.Core/PKM/PK2.cs +++ b/PKHeX.Core/PKM/PK2.cs @@ -249,31 +249,6 @@ namespace PKHeX.Core return Stats; } - public override bool IsGenderValid() - { - int gv = PersonalInfo.Gender; - - switch (gv) - { - case 255: - return Gender == 2; - case 254: - return Gender == 1; - case 0: - return Gender == 0; - - case 31: - return IV_ATK >= 2 ? Gender == 0 : Gender == 1; - case 63: - return IV_ATK >= 5 ? Gender == 0 : Gender == 1; - case 127: - return IV_ATK >= 7 ? Gender == 0 : Gender == 1; - case 191: - return IV_ATK >= 12 ? Gender == 0 : Gender == 1; - } - return false; - } - public override bool IsEgg { get; set; } public override int Gender @@ -294,7 +269,7 @@ namespace PKHeX.Core case 63: return IV_ATK >= 5 ? 0 : 1; case 127: - return IV_ATK >= 7 ? 0 : 1; + return IV_ATK >= 8 ? 0 : 1; case 191: return IV_ATK >= 12 ? 0 : 1; } @@ -307,6 +282,7 @@ namespace PKHeX.Core public override bool HasOriginalMetLocation => CaughtData != 0; #region Future, Unused Attributes + public override bool IsGenderValid() => true; // not a separate property, derived via IVs public override uint EncryptionConstant { get => 0; set { } } public override uint PID { get => 0; set { } } public override int Nature { get => 0; set { } }