Adding a trackball would require dedicated GPIO pins and the ability to translate it like a mouse ball. It's possible and that would be the way to do it, but I don't know how to achieve it directly. There was a project which I saw someone had built, but I can't remember how it was put together. Now, if possible and if you can get a mouse to work, you MIGHT just see if you can wire a USB mouse board (ball type) to the trackball and see what comes out. You could even get two more buttons out of the deal if it goes well. With that said, if all of your buttons are GPIO, you should be alright. If not, you'll need to converse with the MAME designers probably.