calculating if something is in the active area or not is explained in the isoutsideactivearea(function' explanation later in this when we create new enemy squirrel or grass objectswe don' want them to be created inside the view of the camerasince it'll appear that they just pop out of nowhere but we also don' want to create them too far away from the camerabecause then they may never wander into the camera' view inside the active area but outside the camera is where squirrel and grass objects can safely be created alsowhen squirrel and grass objects are beyond the border of the active area then they are far away enough to delete so that they don' take up memory any more objects that far away aren' needed since it is much less likely that they'll come back into view of the camera if you have ever played super mario world on the super nintendothere is good youtube video explaining how super mario world' camera system works you can find this video at keeping track of the location of things in the game world grassobjs [stores all the grass objects in the game squirrelobjs [stores all the non-player squirrel objects stores the player object playerobj {'surface'pygame transform scale(l_squir_img(startsizestartsize)) 'facing'left 'size'startsize ' 'half_winwidth ' 'half_winheight 'bounce': 'health'maxhealth moveleft false moveright false moveup false movedown false the grassobjs variable holds list of all the grass objects in the game as new grass objects are createdthey are added to this list as grass objects are deletedthey are removed from this list the same goes for the squirrelobjs variable and the enemy squirrel objects the playerobj variable is not listbut just the dictionary value itself the move variables on lines to track which of arrow keys (or wasd keysare being held downjust like in few of the previous game programs email questions to the authoral@inventwithpython com