I did as you suggested and then remapped the controller as a NES controller in emulation station. Unfortunately I still have the same problem: The controller works in emulation station but not the games. Now it recognizes a NES controller on port 0 and on port 1 according to the dialogue on the bottom left when I start a game, but no button inputs are working.
Checking the js in /dev/input/ I have found that js1 is the controller I have plugged in and js0 is the keyboard. js2 is recognized as another NES controller but I don’t have one hooked up yet.
Do I need to somehow get the NES controller to be js0?