Ok, so I got dkong and its variants working. Turns out I had to change the mask addresses for a 4-way stick. Now the problem is games like 19xx and 1941, where both joysticks are assigned to the same port (IN0). What's the trick in that instance?
----------------------
I have officially retired from sucking at everything I do. Life is much easier now.