def __init__(self, game): Avatar.__init__(self, game) app = clientapp.singleton() # get rid of pyglet from this class! img = pyglet.resource.image('ball.png') self.sprite = app.renderer.get_sprite(img, self.get_position())
def tick(self, dt): Avatar.tick(self, dt) self.sprite.position = self._position