Hello, dear friend, you can consult us at any time if you have any questions, add WeChat: daixieit


Programming Project - Assignment 1

Knowledge & Reasoning 2021/22 UG 3rd Year

[50% of total module marks]


Overview

Please read this brief carefully and make sure you comply with ALL submission requirements.

This individual assignment is worth 50% of your total Knowledge & Reasoning module marks.

        The task is to construct and document a Checkers game (English draughts) in Java or Pythonusing the object-oriented programming paradigm. The program should present an interactive game board that allows pieces to be moved around by the human player and the AI as per the following basic rules of the game: https://a4games.company/checkers-rules-and-layout/

        Any of the marking criteria below that are not explicitly specified by these rules can be implemented as you see fit. Your program should produce legal gameplay with reasonable performance, as well as different levels of difficulty, and employ an AI core that is based on your implementation of an algorithm that uses Minimax with Alpha-Beta pruning.

        You may think about and start working on this assignment as soon as you like but bear in mind that the lectures on Game-playing, Minimax, and Alpha-Beta pruning will be given in weeks 5 and 6 of the term. Until then, use your time to brush up on object-oriented programming generally and on how to create user interfaces specifically. Normally, it will make sense to start programming after the lectures which cover the implementation of Minimax and Alpha-Beta pruning in Java. This will leave you plenty of time to complete the assignment, which is normally due in week 10.


Marking Criteria

There are 10 assessment areas, split into two groups: Game Internals (76% of total marks) and Human-Computer Interface (24% of total marks). The assessment areas contain further individual criteria for your guidance and are worth different amounts of marks (Total: 100). When developing your program, you should try to satisfy as many of these as you can.

        Note that individual marks will be qualified by your code and the contents of your report, and there may be deductions of varying degree for omissions, inefficiencies, insufficient documentation / explanation, or any mistakes made. You are not primarily marked on the style or quality of your code, but try to adhere to common programming practices to avoid deductions. This includes: Abstraction and modularisation of classes and methods, producing loosely coupled and highly cohesive code, avoiding code duplication, and providing a good degree of code readability (sensible naming of classes and methods plus explanatory comments, where helpful).


Your code must compile and run. If it does not, then you may receive 0 marks for your submission. Before submission, test your program on an Informatics Lab PC. If possible, also run your executable file on a different computer to confirm that it works outside of your own programming environment.


Game Internals

1. Gameplay (20 marks)

a. Interactive checkers gameplay (Human vs. Computer) of some sort

b. Different levels of verifiably effective AI cleverness, adjustable by the user

2. Search algorithm (20 marks)

a. Appropriate and efficient state representation

b. Reasonable successor function to generate AI moves

c. Minimax evaluation

d. Alpha-Beta pruning

e. Appropriate use of heuristics

3. Validation of moves (16 marks)

a. No invalid moves carried out by the AI

b. Automatic check for valid user moves

c. Rejection of invalid user moves, with a specific explanation given

d. Forced capture – if a player can capture an enemy piece they have to do so. If there is more than one capturing opportunity in the same turn, the user may choose which one to take.

4. Other features (20 marks)

a. Multi-leg capturing moves for the user

b. Multi-leg capturing moves for the AI

c. King conversion at baseline (The king’s row) as per the normal rules

d. Regicide - if a normal piece manages to capture a king, it is instantly crowned king and then the current turn ends.

e. Some kind of help feature that can be enabled at the user’s request to get hints about available moves, given the current game state. Sophisticated implementations should employ the AI functionality to make suggestions on optimal moves.


Human-Computer Interface (up to 4 marks each)

5. Some kind of board representation displayed on screen

6. The interface properly updates the display after completed moves (User and AI moves)

7. Fully interactive GUI that uses graphics (You are permitted to use tools that make it easier to construct a GUI by generating the necessary code, such as layout managers provided with Java IDEs like Eclipse or NetBeans)

8. Mouse interaction focus, e.g., click to select & click to place, or drag & drop (better)

9. GUI pauses appropriately to show the intermediate steps of any multi-leg moves

10. Dedicated display of the rules (e.g., a corresponding button opening a pop-up window)


Report

Your report is a very important part of the assessment and required to confirm that you have written the program yourself and understand the AI functionality implemented in it. Your report should therefore refer to the relevant marking criteria that you have addressed, with detailed explanation provided, and specific references to your source code. If you document your code extensively during development, then this will be a lot easier to do and you need less explanation in the actual report text. For this reason, there is no minimum word count given, but as a guideline, try not to exceed 2000-2500 words in total (excluding Appendix).