scoreboard py def prep_level(self)"""turn the level into rendered image ""self level_image self font render(str(self stats level)trueself text_colorself ai_settings bg_colorposition the level below the score self level_rect self level_image get_rect(self level_rect right self score_rect right self level_rect top self score_rect bottom the method prep_level(creates an image from the value stored in stats level and sets the image' right attribute to match the score' right attribute it then sets the top attribute pixels beneath the bottom of the score image to leave space between the score and the level we also need to update show_score()scoreboard py def show_score(self)"""draw scores and ships to the screen ""self screen blit(self score_imageself score_rectself screen blit(self high_score_imageself high_score_rectself screen blit(self level_imageself level_rectthis adds line to draw the level image to the screen we'll increment stats level and update the level image in check_bullet_ alien_collisions()game_ functions py def check_bullet_alien_collisions(ai_settingsscreenstatssbshipaliensbullets)--snip-if len(aliens= if the entire fleet is destroyedstart new level bullets empty(ai_settings increase_speed( increase level stats level + sb prep_level(create_fleet(ai_settingsscreenshipaliensif fleet is destroyedwe increment the value of stats level and call prep_level(to make sure the new level is displayed correctly to make sure the scoring and level images are updated properly at the start of new gametrigger reset when the play button is clickedgame_ functions py def check_play_button(ai_settingsscreenstatssbplay_buttonshipaliensbulletsmouse_xmouse_y)"""start new game when the player clicks play ""button_clicked play_button rect collidepoint(mouse_xmouse_yif button_clicked and not stats game_activescoring