Ethan Glasser-Camp wrote:
I've had similar problems as Joe Johnston in the past when working with joysticks. Generally what's going on is that the joystick driver is holding information and only "updating" a few times a second, whereas if you're going to read "gestures", a la Street Fighter, the entire gesture may go by in 100-200ms. Sometimes there's a way to ask the joystick driver to update with more frequency, or to poll the way Joe Johnston suggests, but I don't see a way to do that in the API documentation.
Thanks Ian for the initial response. I agree with Ethan that the import statement isn't likely to be the cause of the problem. That simply imports symbols into the current namespace.
I sort of guessed my problem was an update issue. I suppose I'll just go with the polling option, which will check the status of the joystick
every time through the main loop.The code I posted was pretty rough. I hope to move to an MVC model, which appears to use events more extensively.
Perhaps this isn't a big issue, but it would be nice to update the docs on pygame.org to mention this issue.
Thanks again for the responses, --Joe