Maru Kun

46%
Flag icon
The game is controlled by a while loop ➌ that contains an event loop and code that manages screen updates. An event is an action that the user performs while playing the game, such as pressing a key or moving the mouse. To make our program respond to events, we’ll write an event loop to listen for an event and perform an appropriate task depending on the kind of event that occurred. The for loop at ➍ is an event loop.
Python Crash Course: A Hands-On, Project-Based Introduction to Programming
Rate this book
Clear rating