You can use this code for the other sprite too. You will just need to change the keys that are pressed.