An open API service indexing awesome lists of open source software.

https://github.com/dantondanvin/chess_bot

An interactive chess game with an AI opponent, implemented in JavaScript
https://github.com/dantondanvin/chess_bot

bot chess chess-ai chess-bot chess-engine chess-game html-css-javascript javascript

Last synced: 4 months ago
JSON representation

An interactive chess game with an AI opponent, implemented in JavaScript

Awesome Lists containing this project

README

          

# Chess Bot ♟️

![JavaScript](https://img.shields.io/badge/language-JavaScript-yellow)
![Version](https://img.shields.io/badge/version-1.0-blue)
![GitHub stars](https://img.shields.io/github/stars/DantonDanvin/chess_bot?style=social)
![GitHub forks](https://img.shields.io/github/forks/DantonDanvin/chess_bot?style=social)
![GitHub issues](https://img.shields.io/github/issues/DantonDanvin/chess_bot)
![GitHub pull requests](https://img.shields.io/github/issues-pr/DantonDanvin/chess_bot)
![GitHub last commit](https://img.shields.io/github/last-commit/DantonDanvin/chess_bot)
![GitHub repo size](https://img.shields.io/github/repo-size/DantonDanvin/chess_bot)
![GitHub contributors](https://img.shields.io/github/contributors/DantonDanvin/chess_bot)
![GitHub commit activity](https://img.shields.io/github/commit-activity/m/DantonDanvin/chess_bot)
![GitHub code size in bytes](https://img.shields.io/github/languages/code-size/DantonDanvin/chess_bot)

This project is an interactive chess game with an AI opponent, implemented in JavaScript. ♔♕♖♗♘♙

## Features 🚀

- Play chess against an AI opponent 🤖
- Interactive chessboard with piece movement ♟️
- Move validation ✅
- Auto-move mode 🔄
- Free mode for piece placement 🆓
- Move analysis 🔍

## Files 📁

- `index.html`: The main HTML file that structures the web page 🌐
- `chess_js.js`: Contains the game logic and user interface interactions 🧠

## How to Use 🎮

1. Open `index.html` in a web browser to start the game. 🌐
2. Click on a piece to select it, then click on a valid square to move. 🖱️

## AI Implementation 🧠

The AI uses the minimax algorithm with alpha-beta pruning to determine the best move. The evaluation function considers piece values and positional advantages. 🤖♟️

Feel free to contribute to this project by submitting pull requests or reporting issues! 🙌