Adding the board

The first thing we will place on the stage is the game board.

The idea: We just need to draw a game board that looks like the one in the original board game. A rectangle with a series of holes will fit our needs.

The development: In connect4.fla, create a new Movie Clip symbol called board_movieclip and set it as exportable for ActionScript. Leave all other settings at their default values, just like you did in previous chapters. Then draw a rectangle with registration point at 0,0 and create the holes, doing something like this:

Adding the board

From the picture you can easily determine the size of the board, in pixels:

  • width: 60 pixels * 7 columns ...

Get Flash Game Development by Example now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.