This is an implementation of the word game Boggle in Python using Tkinter for the graphical interface.
- Generates a random 4x4 Boggle board using a list of letter dice
- Allows the user to click on letters to form words
- Checks if user-created words are valid against a dictionary file
- Keeps track of score and time remaining
- Python 3
- Tkinter module
Run boggle.py
to start the game. A 4x4 board of random letters will be displayed. Click on adjoining letters to form words. When done, click the Submit button to submit the word. Valid words will be added to the score. An invalid word will produce an error message.
The timer starts at 3 minutes. Try to find as many words as possible before time runs out!
boggle.py
- Main game GUI and logicboggle_board_randomizer.py
- Generates random Boggle boardsboggle_dict.txt
- Dictionary of valid wordsex11_utils.py
- Helper functions for finding words on board
The board is represented as a 2D list of letters. The select_letter
function tracks the sequence of clicked letters. submit_word
checks the word against the dictionary and updates the score accordingly.
The valid word dictionary can be changed by modifying boggle_dict.txt
. The board size, number of dice, and timer length can be adjusted by changing constants in boggle.py
and boggle_board_randomizer.py
.
Boggle game idea and rules by Hasbro. Letter dice data from Wikipedia.