2048 Game built using tkinter. The game comes with integrated AI which uses the Monte Carlo Tree Search algorithm to find the best possible move at any given step.
- Make sure you have tkinter module.
pip install tk
- Clone this repository.
git clone https://github.com/akshat-rawat/2048.git
- Start the game and use “a”, “w”, “s” and “d” keys to move tiles left, up, down and right respectively.
python main.py
- Get to 2048 and you win.
- However, you can also fire up the AI to solve the game for you.
- Just click the “i” key and the AI will start right up.
constants.py
initializes required constants.ai_logic.py
implements MCTS for AI.logic.py
contains the functionality of the game.main.py
compiles of all the module and frontend for the game.