import pygame class UserController: def __init__(self, usrObj): self.obj = usrObj def handler(self, engine): for event in pygame.event.get(): if event.type == pygame.QUIT: engine.quit()