Step 9: Try Other Features
To learn more, try changing icons and colors, adding a game timer, and adding sounds. To make the game more challenging, try making the board bigger and adjusting the timer.
To download a completed version of the sample, see Complete Matching Game tutorial sample.
To try other features
Replace the icons and colors with ones you choose.
Try looking at the label's Forecolor property.
Add a game timer that tracks how long it takes for the player to win.
To do this, you can add a label to display the elapsed time on the form above the TableLayoutPanel, and add another timer to the form to track the time. Use code to start the timer when the player starts the game, and stop the timer after they match the last two icons.
Add a sound when the player finds a match, another sound when the player uncovers two icons that don't match, and a third sound when the program hides the icons again.
Make the game more difficult by making the board bigger.
You'll need to do more than just add rows and columns to the TableLayoutPanel – you'll also need to consider the number of icons you create.
Make the game more challenging by hiding the first icon if the player is too slow to respond and doesn't choose the second icon before a certain amount of time.
To continue or review
There are great, free video learning resources available to you. To learn more about programming in Visual Basic, see Visual Basic Fundamentals: Development for Absolute Beginners. To learn more about programming in Visual C#, see C# Fundamentals: Development for Absolute Beginners.
To return to the previous tutorial step, see Step 8: Add a Method to Verify Whether the Player Won.