starshipmeteors pygame class gameobjectdef load_image(selffilename)self image pygame image load(filenameconvert(self width self image get_width(self height self image get_height(def rect(self)""generates rectangle representing the objects location and dimensions ""return pygame rect(self xself yself widthself heightdef draw(self)""draw the game object at the current xy coordinates ""self game display_surface blit(self image(self xself )class starship(gameobject)""represents starship""def __init__(selfgame)self game game self display_width self display_height self load_image('starship png'def move_right(self)""moves the starship right across the screen ""self self starship_speed if self self width display_widthself display_width self width def move_left(self)""move the starship left across the screen ""self self starship_speed if self self def move_up(self)""move the starship up the screen ""self self starship_speed if self self def move_down(self)""move the starship down the screen ""self self starship_speed if self self height display_height