first demo for displaying chopper sprites.
This commit is contained in:
16
chopper.py
Normal file
16
chopper.py
Normal file
@@ -0,0 +1,16 @@
|
||||
|
||||
class Chopper:
|
||||
|
||||
def __init__(self,xpos,ypos,state):
|
||||
self.xpos = xpos
|
||||
self.ypos = ypos
|
||||
self.state = state
|
||||
self.STATE_FRONT=0
|
||||
self.STATE_RIGHT=1
|
||||
self.STATE_LEFT = 2
|
||||
self.images = {}
|
||||
|
||||
|
||||
def add_sprite(self,state,sprite):
|
||||
self.images[state] = sprite
|
||||
|
||||
Reference in New Issue
Block a user