How do I add a Circle that moves in this?
I'm a beginner at graphics and could someone help me add a circle above the purple half that moves with keys a and d?
you have to change the coordinates of the circle each time the loop passes
for event in pygame.event.get(): if event.type == pygame.QUIT: pygame.quit() quit() if event.type == pygame.KEYDOWN: if event.key == pygame.K_LEFT: # do stuff with left key if event.key == pygame.K_RIGHT: # do stuff with right key
should be something like pygame.draw.circle(color, color,color),(x,y)
and to make it move you need up update the location of its x cordinate when the key is pressed