pygame event code example
Example 1: how to pring events in pygame
import pygame
pygame.init()
screen = pygame.display.set_mode((500,300))
thing = 0
while thing < 100000000:
thing += 1
event = pygame.event.get()
print (event)
pygame.quit()
Example 2: pygame.event.get() in pygame
for event in pygame.event.get():
if event.type == pygame.QUIT:
# Close the program any way you want, or troll users who want to close your program.
raise SystemExit