0

I've made several small programs in PyGame and for my latest attempt I have added scrolling (push arrow keys) but when it happens the sprites flicker. I've tried to pinpoint the issue but cannot.

The drawing section happens in engine.screen.py redraw() and update_window()

Github repository of code

Teifion
  • 108,121
  • 75
  • 161
  • 195

2 Answers2

2

Have you considered swapping lines 48 and 49 in screen.py? :) Not sure, but maybe you ought to call display.flip() after rendering the sprites?

Johannes Charra
  • 29,455
  • 6
  • 42
  • 51
0

Do you have vertical sync enabled? And set framerate to 60, for a nice look.

ninMonkey
  • 7,211
  • 8
  • 37
  • 66