HTML and CSS Reference
In-Depth Information
Figure 6-10. Video puzzle
Setting up the game
To start, we are going to set up some variables that will define the game's playfield. Here is a
rundown of the variables and how they will be used:
rows
rows
The numbers of rows in the grid of puzzle pieces.
cols
The number of columns in the grid of puzzle pieces.
xPad
xPad
The space, in pixels, between each column.
yPad
The space, in pixels, between each row.
Search WWH ::




Custom Search