https://github.com/ranagaballah/connectfour_python_with_gui
USing Pygame
https://github.com/ranagaballah/connectfour_python_with_gui
connect-four gui minimax-algorithm minimax-alpha-beta-pruning pygame python
Last synced: 11 months ago
JSON representation
USing Pygame
- Host: GitHub
- URL: https://github.com/ranagaballah/connectfour_python_with_gui
- Owner: RanaGaballah
- Created: 2023-05-19T20:19:35.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-05-19T22:50:22.000Z (about 3 years ago)
- Last Synced: 2025-07-04T13:08:39.362Z (12 months ago)
- Topics: connect-four, gui, minimax-algorithm, minimax-alpha-beta-pruning, pygame, python
- Language: Python
- Homepage: https://www.linkedin.com/posts/rana-gaballah-9a5299219_connect4-python-pygame-activity-7065453757207068672-iJV4?utm_source=share&utm_medium=member_desktop
- Size: 125 KB
- Stars: 0
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Certainly! Here's an example of a README file for the ConnectFour_Python_With_GUI repository:
# Connect Four Python Game with GUI
This repository contains a Connect Four game implemented in Python with a graphical user interface (GUI).
## Features
- Play Connect Four against a computer opponent.
- Interactive GUI for an intuitive gaming experience.
- Customizable difficulty levels.
- Win detection and game over condition.
- Simple and clean user interface.
## Getting Started
### Prerequisites
- Python 3.x
- numpy library
- pygame library
### library Installation
```
pip install numpy
```
```
pip install pygame
```
### Installation
1. Clone the repository:
```
git clone https://github.com/RanaGaballah/ConnectFour_Python_With_GUI.git
```
2. Navigate to the project directory:
```
cd ConnectFour_Python_With_GUI
```
### Usage
Run the `connect_four.py` file to start the game:
```
python connect_four.py
```
Follow the on-screen instructions to play the game. Use the mouse to select a column for your move.
### Game Rules
- The objective of the game is to connect four of your own pieces in a row, column, or diagonal before your opponent does.
- Players take turns dropping their colored discs into a grid.
- The discs will fall down to the lowest available position within the selected column.
- The game continues until one player wins or the board is full (resulting in a draw).
## Contributing
Contributions to this project are welcome. Here are a few ways you can contribute:
- Report bugs or suggest improvements by opening a GitHub issue.
- Fork the repository and submit a pull request with your enhancements.
- Share the game and give it a star if you find it useful.
## License
This project is licensed under the [MIT License](LICENSE).
## Acknowledgments
- The game logic and AI algorithm are based on the work of [Rana Gaballah](https://github.com/RanaGaballah).
- Special thanks to the creators and maintainers of the Tkinter library for providing a simple and powerful GUI toolkit for Python.