/PHP-CLI-Tic-Tac-Toe

An OO PHP5 implementation of Tic Tac Toe, to be played on the command line. Can play humans or the AI.

Primary LanguagePHP

PHP CLI Tic Tac Toe Game

This is a very OO implementation of a game of Tic Tac Toe which can be played on the command line, developed in PHP for a 24 hour challenge. It allows players to play eachother, or to play against a bot, or even a bot to play against another bot.

The AI is currently buggy and doesn't act totally defensively, it's a similar implementation to that of MiniMax, which it may evolve to be.

As this is still a prototype, it wasn't developed using tests. Tests will be added shortly as I do plan to fix the bugs with the AI, test out new implementations and refactor the code-base.

To launch the game simply run '$ /usr/bin/php tic_tac_toe.php', or use php-cli!

This was developed by Mark Gannaway as an experiment for using PHP for I/O command line applications. It turns out to be pretty easy!