pygame display set_mode(function is special because anything drawn on that surface object is displayed on the user' screen when pygame display update(is called pygame event event the pygame event module generates event objects whenever the user provides keyboardmouseor another kind of input the pygame event get(function returns list of these event objects you can check what type of event the event object is by checking its type attribute quitkeydownand mousebuttonup are examples of some event types pygame font font the pygame font module has the font data type which represents the typeface used for text in pygame the arguments to pass to pygame font sysfont(are string of the font name and an integer of the font size however it is common to pass none for the font name to get the default system font pygame time clock the clock object in the pygame time module is helpful for keeping our games from running as fast as possible the clock object has tick(methodwhich we pass how many frames per second (fpswe want the game to run at the higher the fpsthe faster the game runs type in the following code and save it to file named dodger py this game also requires some other image and sound fileswhich you can download from the url source code of dodger you can download this code from the url this code incompare the code you typed to the book' code with the online diff tool at import pygamerandomsys from pygame locals import windowwidth windowheight textcolor ( backgroundcolor ( fps baddieminsize baddiemaxsize baddieminspeed baddiemaxspeed addnewbaddierate playermoverate def terminate()post questions to