A brief description of the Connect Four Game AI
In this task, we will discuss the general mechanism of the game. We will discuss the function calls used, game flow, and a general idea of the game mechanism. It would be a good idea to follow this code review along with the game code available in this project.
Prepare for lift off
We are building this arcade game based on the code from Making Games with Python & Pygame by Al Sweigart (http://inventwithpython.com/makinggames.pdf). This book is an interesting read and it should enable us to build our own arcade game (not necessarily the Connect Four game).
Engage thrusters
Let's get started with reviewing the general structure of the game using the flowchart shown in the following diagram:
The first step is to import the modules required to launch and play the game. This includes the
pygame
,pygame.mixer
,piface
, andserial
modules.After importing the requisite modules, game parameters such as game difficulty, board size in terms of width and...