* Initial bred moveset validation logic
Unpeel the inheritance via recursion and permitted moves
* Volt tackle considerations
* Optimize out empty slot skips
* Add tests, fix off-by-one's
* Require all base moves if empty slot in moveset
* Add test to prove failure per Anubis' provided test
* Tweak enum labels for easier debugging
When two enums share the same underlying value, the ToString/name of the value may be either of the two (or the last defined one, in my debugging). Just give it a separate magic value.
* Fix recursion oopsie
Also check for scenario where no-base-moves but not enough moves to push base moves out
* Add Crystal tutor checks
* Add specialized gen2 verification method
Game loops through father's moves and pushes in one iteration, rather than checking by type.
* Add another case with returning base move
* Add push-out requirement for re-added base moves
* Minor tweaks
Condense tests, fix another off-by-one noticed when creating tests
* Disallow inherited parent levelup moves
Disallow volt tackle on Gen2/R/S
* Split MoveBreed into generation specific classes
Gen2 behaves slightly different from Gen3/4, which behaves slightly different from Gen5... and Gen6 behaves differently too.
Add some xmldoc as the api is starting to solidify
* Add method overload that returns the parse
Verify that the parse order is as expected
* Add reordering suggestion logic
Try sorting first, then go nuclear with rebuilding.
* Return base moves if complete fail
* Set base moves when generating eggs, only.
* Use breed logic to check for egg ordering legality
Don't bother helping for split-breed species
New legality checks for Transfer Console Region permitted, and removing the inaccessible areas (R1 outskirts rockruff) resulted in these being flagged.
Mutate the data so it's now legal with the updated rules.
AltForm & Form & Forme => Form
GenNumber & Generation => Generation
Extract out SpeciesForm interface, and re-add IGeneration
For those using PKHeX as a dependency, this should be a pretty straightforward manual replacement... GenNumber and AltForm should be quick find-replace`s.
Transporter remaps certain locale specific chars depending on the source ROM's version.
Since VC can trade between languages, there are 2 Spanish in-game trades that have glyphs subject to remapping, if it's transferred from a French game.
If the spanish trade is transferred from a french game, it must match the mutated string.
ty @Lusamine & helpers :D
Closes#3027
Roamers: Get PID generated externally
NPokemon: Get PID from a fixed value
Forced (Anti)Shiny: Get PID altered
Thanks @LegoFigure11 && Princess Emily (discord 4650) !
Closes#2990 ty @Atrius97 !
Remove the `object Content` accessor only used for Mystery Gifts (used to trickle up the PKM object since the two ribbon interfaces weren't implemented on the IEncounterable). Just make PCD/PGT implement the ribbon interfaces and delegate the get/set to PKM directly.
Rewrite the national ribbon check for clarity
Optimize invalid/missing ribbon string replace to operate on the final string rather than do linq and replace each input. With this we make 1 temp string only, rather than 1-per-ribbon.
Replace hardcoded "Ribbon" strings to use a shared const string in a central spot.
* Fix broken hidden power power calculation
* Fix broken Gen 2 Hidden Power calculation
* Add parentheses
* WIP UI
* Finalize UI, only show on gens 1-5
* Inline some logic to reduce allocations
* Add unit tests for both hidden power calculation cases
Co-authored-by: Kurt <kaphotics@gmail.com>
Closes#2984
ty atrius & matt via discord
Co-Authored-By: Atrius97 <39707481+Atrius97@users.noreply.github.com>
Co-Authored-By: Matt <17801814+sora10pls@users.noreply.github.com>
EncounterTrade: don't init Location to -1; keep as default 0 and use that as the pivot for default met location. Move Fateful property to the sub-type that uses it (EncounterTrade4, for Ranch).
Move some EncounterStatic->PKM logic that is per-type to the associated type overloaded methods. Rearrange order of properties to be more consistent with interfaces
Gen3: Initialize some classes without using post-constructor setters. The `init` setter functionality coming in c#9 won't be usable as the net46 runtime/netstandard2 doesn't support it on current previews. Do it this way so we can explicity initialize some required properties rather than apply version on a second iteration.
XD compares the player TSV against the non-shadow members, which is unnecessary but does result in them being able to cause shiny skips.
Update the VerifyNPC method to remove tsv check, as it's just repeating the logic we've done in the lock generator.
Added a test method that can be stepped through; compare the team results manually since they aren't exposed for interaction.
Closes#2751 , big thanks to @ijuintekka for being so detailed in their investigation/report!
Co-Authored-By: ijuintekka <ijuintekka@users.noreply.github.com>