26 lines
620 B
Python
26 lines
620 B
Python
import pygame
|
|
|
|
|
|
def interpret( event ):
|
|
|
|
# remove this after adding code
|
|
pass
|
|
|
|
# key press interpretation here
|
|
# add calls to sapper object's movement functions
|
|
# TODO : key press interpretation goes here
|
|
|
|
|
|
#
|
|
# TINY SAMPLE FROM MY PYGAME TEST
|
|
# (had trouble with figuring this out)
|
|
#
|
|
# # this part is true, when you press a key down
|
|
# # there's also a KEYUP for letting go
|
|
# if event.type == pygame.KEYDOWN:
|
|
#
|
|
# # this part is true, when a key u pressed down is the left arrow
|
|
# if event.key == pygame.K_LEFT:
|
|
# # here should be a call to sapper's movement function
|
|
#
|