Learn pygame - Event handling. ... There are two types of key events in pygame: KEYDOWN and KEYUP . ... K_q]: # Press 'q' to exit the program quit().
確定! 回上一頁