Question: Assignment 1 : Three Musketeers Description This assignment s major learning goal is object oriented design in Java Design basic classes Each class must be

Assignment 1: Three Musketeers
Description
This assignments major learning goal is object oriented design in Java
Design basic classes
Each class must be small and do one thing (Single Responsibility Principle)
The design must start from abstractions (Dependency Inversion)
Must use inheritance, composition, and polymorphism
We will make use of the Three Musketeers Board game. This game is played on a 5x5 square board:
Starter Board
| A B C D E
+
1| O O O O X
2| O O O O O
3| O O X O O
4| O O O O O
5| X O O O O
MUSKETEER - A musketeer moves to an adjacent (just orthogonal) cell occupied by a guard (capturing it).
GUARD - A guard moves to an adjacent (just orthogonal) empty cell.
TURNS - On the first turn the musketeer side moves. Then, turns alternate.
GOAL - The musketeer wins if they cannot make a valid move and the 3 musketeers are not on the
same row or column. The guard wins if the 3 musketeers are on the same row or column.
Example: Guards turn

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!