moving the spaceship the problem is that we are redrawing the starship at different positionbut the previous image is still present we now have two choices one is to merely fill the whole screen with blackeffectively hiding anything that has been drawn so faror alternatively we could just draw over the area used by the previous image position which approach is adopted depends on the particular scenario represented by your game as we will have lot of meteors on the screen once we have added themthe easiest option is to overwrite everything on the screen before redrawing the starship we will therefore add the following lineclear the screen of current contents self display_surface fill(backgroundthis line is added just before we draw the starship within the main game playing while loop now when we move the starship the old image is removed before we draw the new imageone point to note is that we have also defined another global value background used to hold the background colour of the game playing surface this is set to black as shown below