In the last lesson (Lesson 2), we created the Tic-Tac-Toe Board and GameBall classes. We also added GameBall objects to the Board object. In this lesson, we will add a Player class such that a Player object interacts with GameBall objects in a meaningful way.

In this lesson, we will make the Board class check the game progress and stop the game once someone has won. I will then introduce the concept of Java Arrays. We will add code to constantly check whether three game balls of the same color has lined up and to mark those winning game balls.

This post shows you how to create a simple project in Eclipse using SmartGWT.
PS If you have trouble viewing the images on this post, you are likely behind a firewall which blocks Google Drive content. You can download this page’s PDF file.

Have you heard of Scratch? No, not what you do to your itch, but Scratch from MIT the famous school for the curiously brainy people? If you have not heard, seen, or played with Scratch, then you’ve been missing out. Because it is a lot of FUN!!!