Cosplay pikachu fixes

Form can be changed only for the received cosplay Pikachu.
Can be obtained in any location.
Regular Pikachu cannot be given a cosplay-only form
Cosplay Pikachu cannot have a non-cosplay form.
This commit is contained in:
Kaphotics 2016-04-23 14:16:12 -07:00
parent 150d781699
commit c2981510a9
2 changed files with 11 additions and 3 deletions

View file

@ -632,6 +632,12 @@ namespace PKHeX
switch (pk6.Species) switch (pk6.Species)
{ {
case 25:
if (pk6.AltForm != 0 ^ EncounterType == typeof(EncounterStatic))
return EncounterType == typeof(EncounterStatic)
? new LegalityCheck(Severity.Invalid, "Cosplay Pikachu cannot have the default form.")
: new LegalityCheck(Severity.Invalid, "Only Cosplay Pikachu can have this form.");
break;
case 664: case 664:
case 665: case 665:
if (pk6.AltForm > 17) // Fancy & Pokéball if (pk6.AltForm > 17) // Fancy & Pokéball

View file

@ -412,7 +412,6 @@
internal static readonly int[] WildPokeballs = { 0x01, 0x02, 0x03, 0x04, 0x06, 0x07, 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F }; internal static readonly int[] WildPokeballs = { 0x01, 0x02, 0x03, 0x04, 0x06, 0x07, 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F };
internal static readonly int[] FormChange = // Pokémon that can change form internal static readonly int[] FormChange = // Pokémon that can change form
{ {
25, // Pikachu
351, // Castform 351, // Castform
386, // Deoxys 386, // Deoxys
412, // Burmy 412, // Burmy
@ -657,8 +656,11 @@
new EncounterStatic { Species = 498, Level = 5, Location = 204, Gift = true }, // Tepig new EncounterStatic { Species = 498, Level = 5, Location = 204, Gift = true }, // Tepig
new EncounterStatic { Species = 501, Level = 5, Location = 204, Gift = true }, // Oshawott new EncounterStatic { Species = 501, Level = 5, Location = 204, Gift = true }, // Oshawott
new EncounterStatic { Species = 25, Level = 20, Location = 186, Gender = 1, Ability = 4, Form = 1, IVs = new[] {-1, -1, -1, 31, -1, -1}, Contest = new[] {70,70,70,70,70,0}, Gift = true, Shiny = false }, // Pikachu new EncounterStatic { Species = 25, Level = 20, Location = 178, Gender = 1, Ability = 4, IVs = new[] {-1, -1, -1, 31, -1, -1}, Contest = new[] {70,70,70,70,70,0}, Gift = true, Shiny = false }, // Pikachu
new EncounterStatic { Species = 25, Level = 20, Location = 186, Gender = 1, Ability = 4, Form = 3, IVs = new[] {-1, -1, -1, 31, -1, -1}, Contest = new[] {70,70,70,70,70,0}, Gift = true, Shiny = false }, // Pikachu new EncounterStatic { Species = 25, Level = 20, Location = 180, Gender = 1, Ability = 4, IVs = new[] {-1, -1, -1, 31, -1, -1}, Contest = new[] {70,70,70,70,70,0}, Gift = true, Shiny = false }, // Pikachu
new EncounterStatic { Species = 25, Level = 20, Location = 186, Gender = 1, Ability = 4, IVs = new[] {-1, -1, -1, 31, -1, -1}, Contest = new[] {70,70,70,70,70,0}, Gift = true, Shiny = false }, // Pikachu
new EncounterStatic { Species = 25, Level = 20, Location = 194, Gender = 1, Ability = 4, IVs = new[] {-1, -1, -1, 31, -1, -1}, Contest = new[] {70,70,70,70,70,0}, Gift = true, Shiny = false }, // Pikachu
new EncounterStatic { Species = 360, Level = 1, EggLocation = 60004, Ability = 1, Gift = true }, // Wynaut new EncounterStatic { Species = 360, Level = 1, EggLocation = 60004, Ability = 1, Gift = true }, // Wynaut
new EncounterStatic { Species = 175, Level = 1, EggLocation = 60004, Ability = 1, Gift = true }, // Togepi new EncounterStatic { Species = 175, Level = 1, EggLocation = 60004, Ability = 1, Gift = true }, // Togepi
new EncounterStatic { Species = 374, Level = 1, Location = 196, Ability = 1, IVs = new[] {-1, -1, 31, -1, -1, 31}, Gift = true }, // Beldum new EncounterStatic { Species = 374, Level = 1, Location = 196, Ability = 1, IVs = new[] {-1, -1, 31, -1, -1, 31}, Gift = true }, // Beldum