Fun little game! Too bad about the removed SNES-controller support? Did you check the Petscii Robot's source code?
https://github.com/zeropolis79/PETSCIIRobots-Pet
There is also a C64-code snippet David posted on his website some years back:
https://www.the8bitguy.com/wp-content/uploads/2021/03/snestest.zip
Maybe this can help you implement SNES-controller-support after all