Reading the conversation at #9888 indicates that the favorable solution is to just hardcode the egg moves into the learnsets of Pokemon like Cap Pikachu. I'm not sure if we still want that or if we eventually wanted to replace it with a generic implementation, but since Cap Pikachu's egg moves are still illegal, some fix is warranted.
Instead of trying to stick in just the egg moves, I'm allowing the entire learnset of the base evolution to be taken, but filtering out everything but the egg moves when going through the learnset of the base evolution. (Side note: checkingMoves is added as a parameter to learnsetParent because it's called by validatePokemonGo to find valid base forms rather than for learnset reasons)
https://www.smogon.com/forums/threads/cap-pikachu-should-be-able-to-learn-egg-moves.3742218/
Reading the conversation at #9888 indicates that the favorable solution is to just hardcode the egg moves into the learnsets of Pokemon like Cap Pikachu. I'm not sure if we still want that or if we eventually wanted to replace it with a generic implementation, but since Cap Pikachu's egg moves are still illegal, some fix is warranted.
Instead of trying to stick in just the egg moves, I'm allowing the entire learnset of the base evolution to be taken, but filtering out everything but the egg moves when going through the learnset of the base evolution. (Side note: checkingMoves is added as a parameter to learnsetParent because it's called by validatePokemonGo to find valid base forms rather than for learnset reasons)