Jonnect Jour
2015-08-15, post № 55
games, programming, Pygame, Python, #4, #connect, #connecting, #detection, #four, #four in a row, #game, #IV, #mouse control, #red, #win, #win detection, #yellow
After having programmed Jic-Jac-Joe — where you need to connect three pieces —, I now programmed Connect Four (four pieces).
This version — although it does not have a computer player — includes win detection.
Controls
- Left-clicking puts your piece where the mouse cursor is positioned,
- ‘Escape’ restarts the game.
Source code: jonnect-jour.py
Extra assets: jonnect-jour-2.png, jonnect-jour-4.png