Queen's Gambit
A simple chess app using a minimax algorithm that supports player vs player or player vs AI.
Project is created with:
- React
- Netlify
- Bootstrap version : 5.1.3
- jQuery
- JSX
- CSS
Test out the app here : https://online-ai-chess.netlify.app
- For player vs player : select play against players button or invite friends to play against you using your unique link stated on the app page when you press into the above stated link
- For player vs AI : select play against AI
- Drag and drop the chess piece you would like to move to the desired position. Possible locations are indicated with a grey translucent opacity. If move is not allowed, the chess piece will jump back to its original location until a valid move is made
- Game can end in a victory, loss or draw for both parties. Option for a rematch or return to main menu will be provided then
- Players can undo a move, or reset the board when playing against AI
This was a 3 month long project built during our first year at NUS School of Computing. Project goals included using technologies that we have learnt up till this point, as well as acquiring new skills in software engineering aspect in coding.
While it was rather difficult to put to use and familiarise ourselves with all these freshly picked up technologies used in the app, it was definitely a fulfilling journey and we have gained newfound and crucial knowledge in programming that is cardinal in the job market today for software engineers and we are glad to have been able to embark on this journey of learning.
We chose to use the create-react-app boilerplate to minimize setup and invest more time in diving into weird technological rabbit holes, to make the most out of this project.
An obstacle that we faced was implementing the chess logic vs an AI. However, after an extensive amount of research on the minimax algorithm and optimising it using various weights for the chess pieces based on their relative positions on the board, we managed to make it work.