def ProcessInput(self, events, pressed_keys):
"""
Process Input from user
Inherited from SceneBase
Args: self
events - list of pygame events
pressed_keys
"""
for event in events:
if event.type == pygame.KEYDOWN and event.key == pygame.K_RETURN:
# Move to the next scene when the user pressed Enter
pass
if event.type == pygame.MOUSEBUTTONDOWN:
self.easy_button.isClicked(event)
self.adv_button.isClicked(event)
if event.type == pygame.MOUSEBUTTONUP:
self.easy_button.isClicked(event)
self.adv_button.isClicked(event)
if event.type == pygame.MOUSEMOTION:
self.easy_button.isHovered(event)
self.adv_button.isHovered(event)
评论列表
文章目录