A lot of cracked software in the internet looks like it's liberated with a patched executable and an additional key generator. Why so complicated? If the executable is patched why isn't the necessity for a key completely removed?
One of the possible reasons for this is assymetric encryption used in newer protections. The software vendor has the private key, the public key is embedded in the software. This means you just can't write a key generator from the information that's publicly available. If the key checking itself is heavily protected against modification, it may be easier to roll your own private/public key pair, have your keygen use the private part of this pair, and replace the original public key in the software with yours.
Sometimes, it's better to do so because the target has a powerful protection against trivial patches; therefore, the cracker would make some changes to make the target accepts a generated key (that might not be fully correct) so the target protection would simply collapse because it's (kind of) registered.