Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.
It isn't controlled. The type and power is established once the egg hatches (or you catch the wild Poke) and the IVs are set. That is why I will never believe someone who somehow has a "correct" HP type with an AP over 50. The odds of that are too low to get other than cheating.