Snakes Pygame: Difference between revisions

imported>Jesstess
imported>Jesstess
Line 39:
 
=== 3. Set a key repeat speed ===
 
So far, you have to press an arrow key for each movement of the snake. Wouldn't it be convenient to be able to just hold down an arrow key to keep moving our snake?
 
Fix this by completing the "Set the key repeat speed" TODO in the <code>initialize_screen</code> function in <code>snake.py</code>. See http://www.pygame.org/docs/ref/key.html#pygame.key.set_repeat for details on the Pygame function that controls this behavior.
 
=== 4. Handle quit and restart key presses ===
Anonymous user