Fix bug in Transaction#getAffectedKeys

`Transaction#getAffectedKeys` was trying to call `Script#simpleOutPubKeyHash`, which doesn't exist. I changed it so that `getAffectedKeys` checks that the script is to a pubkey, then gets the pubkey with `simpleOutHash`.

There are multiple other ways to fix this; this might not be the best way -- maybe we want to keep the script type-checking inside `Script`. We could split `simpleOutHash` into `simpleOutPubKeyHash` and `simpleOutAddressHash` and add methods like `isPubKeyOutput`, etc. Please let me know if you have suggestions!