Giter Site home page Giter Site logo

ccl-miniproject's Introduction

Python Chess Engine with AI

Showcase Image

This is a Python-based (pygame) chess engine that allows users to play against a computer opponent or a second player. The engine follows the standard rules of chess and features somewhat efficient move generation using the nega max algorithm. It also includes a beautiful GUI with valid move visualization and a move log.

Features

  • Chess Rules: The engine follows the standard rules of chess including enpassant, castling and moving the pieces
  • AI: Play against your computer using the nega max algorithm which finds the best possible move recursively using alpha beta pruning
  • GUI: The project makes use of the pygame library to create a beautiful graphical user interface and draw text, rectangles and images onto the screen.
  • Extras: such as undoing a move, sound effects and a move log

Getting Started

Prerequisites

  • Python 3

Installation

  1. Clone the repository to your local machine:
git clone https://github.com/0xBitBuster/python-chess-engine.git
  1. Install all requirements using pip:
pip3 install -r requirements.txt

Usage

To start the game you can either do it in your IDE or manually:

python3 ChessMain.py

Quick Note / Todo

This code does not use the python best practice for the naming convention (The project uses camelCasing instead of lowercase_underscore). You can also try to optimize the negamax and find valid moves algorithm. Maybe even create a UI to select wether you want to play against the computer or another player.

Contributing

Contributions are welcome! If you have a feature request or bug report, please open an issue. If you want to contribute code, please fork the repository and submit a pull request.

License

This project is licensed under the MIT License - see the LICENSE file for details.

ccl-miniproject's People

Contributors

0xbitbuster avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.