"revealed revealedboxes[boxx][boxytrue set the box as on line we check if the mouse cursor is not only over covered up box but if the mouse has also been clicked in that casewe want to play the --reveal|animation for that box by calling our revealboxesanimation(function (which isas with all the other functions main(callsexplained later in this you should note that calling this function only draws the animation of the box being uncovered it isn' until line when we set revealedboxes[boxx][boxytrue that the data structure that tracks the game state is updated if you comment out line and then run the programyou'll notice that after clicking on box the reveal animation is playedbut then the box immediately appears covered up again this is because revealedboxes[boxx][boxyis still set to falseso on the next iteration of the game loopthe board is drawn with this box covered up not having line would cause quite an odd bug in our program handling the first clicked box if firstselection =nonethe current box was the first box clicked firstselection (boxxboxy elsethe current box was the second box clicked check if there is match between the two icons icon shapeicon color getshapeandcolor(mainboardfirstselection[ ]firstselection[ ] icon shapeicon color getshapeandcolor(mainboardboxxboxybefore the execution entered the game loopthe firstselection variable was set to none our program will interpret this to mean that no boxes have been clickedso if line ' condition is truethat means this is the first of the two possibly matching boxes that was clicked we want to play the reveal animation for the box and then keep that box uncovered we also set the firstselection variable to tuple of the box coordinates for the box that was clicked if this is the second box the player has clicked onwe want to play the reveal animation for that box but then check if the two icons under the boxes are matching the getshapeandcolor(function (explained laterwill retrieve the shape and color values of the icons (these values will be one of the values in the allcolors and allshapes tuples