pyherc
pyherc copied to clipboard
PyQt, ui thread and game logic
Game logic runs in ui thread, which makes game unresponsive now and then. Animations are pain to control too. Move game logic to a separate thread and see if this helps.
also, animations seem to be causing problems and core dumps
2 threads, worker thread and UI thread. Everything else but drawing, animations and reading input should run in worker thread. Input creates an action and hands it over to worker thread to process. Worker thread raises events as appropriate and they're (somehow) processed by UI thread. If blocking animation is running, action is not passed to worker thread.