class rocket(object):
def __init__(self, x, y):
self.image = pygame.image.load('sprites/spaceship.png')
self.x = x
self.y = y
self.width = 72
self.height = 72
self.speed = 5
self.angle = 0
def draw(self, win):
win.blit(char, (self.x,self.y))
def updateGameWindow():
win.blit(bg, (0,0))
rocket.draw(win)
pygame.display.update()
For some reason when I run this program, I'm getting the error that rocket.draw(win) is missing the argument 'win' when it is clearly there.
win is defined at the top of the program.