Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/princelad/squarelogic
Square Logic is a chess game built using Python and Pygame. It features a visually appealing chessboard, piece movement validation, pawn promotion, and move history tracking. The game ensures smooth gameplay with optimized animations.
https://github.com/princelad/squarelogic
ai board-game chess chess-engines chess-game game-development game-programming pygame pyhton-game python
Last synced: about 23 hours ago
JSON representation
Square Logic is a chess game built using Python and Pygame. It features a visually appealing chessboard, piece movement validation, pawn promotion, and move history tracking. The game ensures smooth gameplay with optimized animations.
- Host: GitHub
- URL: https://github.com/princelad/squarelogic
- Owner: Princelad
- License: mit
- Created: 2024-12-27T15:17:38.000Z (about 1 month ago)
- Default Branch: master
- Last Pushed: 2025-01-31T12:31:21.000Z (4 days ago)
- Last Synced: 2025-01-31T13:23:17.800Z (4 days ago)
- Topics: ai, board-game, chess, chess-engines, chess-game, game-development, game-programming, pygame, pyhton-game, python
- Language: Python
- Homepage:
- Size: 127 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
---
# Square Logic ♟️A simple yet interactive chess game built using **Python** and **Pygame**. This project features an intuitive chessboard, move validation, and user interactions for a smooth chess-playing experience.
## 📌 Features
- **Interactive Chessboard** – Click-based movement with move validation.
- **Move Validation** – Checks for legal moves and prevents invalid ones.
- **Undo Move** – Press `Backspace` to undo the last move.
- **Hover & Selection Highlights** – Enhances visual clarity of moves.
- **Pawn Promotion** – Automatically promotes pawns (default: Queen).
- **Smooth Animations** – Runs at up to 144 FPS for fluid visuals.## 🛠️ Installation
1. **Clone the repository**
```bash
git clone https://github.com/Princelad/SquareLogic.git
cd SquareLogic
```
2. **Install dependencies**
```bash
pip install -r requirements.txt
```
3. **Run the game**
```bash
python Chess/ChessMain.py
```## 🎮 How to Play
- Click on a piece to select it, then click on a valid square to move.
- Press `Backspace` to undo the last move.
- Hovering over squares will highlight them for better visibility.## 📁 Project Structure
```
SquareLogic/
│── images/ # Chess piece images
│── Chess/ # Chess logic and engine
│ ├── ChessEngine.py # Handles game rules and move validation
│ └── ChessMain.py # Main driver script
│── README.md # Project documentation
└── requirements.txt # Dependencies
```## 🖼️ Screenshots
### Game Start
![Game Start](project-images/Game_start.png)### Game State
![Game State](project-images/Game_state.png)
## 🚀 Future Improvements- Add **AI opponent** for single-player mode.
- Enhance UI with **move history and timers**.## 📜 License
This project is licensed under the **MIT License**.
---