This repository contains implementations of Gold Mine games using Python and Tkinter.
-
game.py- A classic Gold Mine game where players navigate through a grid to collect gold while avoiding traps. Features:- 5x5 grid
- 4 gold pieces to collect
- 4 traps to avoid
- Warning indicators for nearby traps
- Move counter
- Player position tracking
-
game1.py- An automated Gold Mine solver that finds the optimal path to collect maximum gold. Features:- Dynamic grid size (4-8 rows/columns)
- Random gold values (1-9)
- Dynamic programming algorithm
- Visual path highlighting
- Color-coded gold values
- Reset functionality
- Make sure you have Python installed with Tkinter support
- Run either game:
or
python game.pypython game1.py
- Click adjacent cells to move the player
- Collect all gold while avoiding traps
- Watch for warning indicators near traps
- Click "Start" to find the optimal path
- Click "Reset" to generate a new random grid