Wumpus World is a classical computer science puzzle game. The user is placed on a grid of cells that represents a cave, and can move to an adjacent cell by going up, down, left, or right. Each cell in the game might contain:
There are many variants to the game, but in this assignment the goal is to find the gold, pick it up, return to the cave entrance (the starting position), and climb out. If the user lands on a cell that contains a Wumpus, then they will be eaten. If they land on a cell that contains a pit, they will fall in and die. If they land on a cell with the gold, they can pick it up and then make their way for the entrance.
To help avoid obstacles and find the gold, the user can:
At each turn, the user can either move (left, right, up, or down), shoot an arrow (left, right, up, or down), grab for gold, or climb out of the cave.
You will a program that plays Wumpus World from a randomly generated game. The constraints of the game will be as follows:
In the screenshot below, the user finds the gold and exits the cave: See image.
Note that when we run the program, even though the board placement is random, we can build this mental model (note that there are likely several more rows above this). Green cells are visited, and red cells are unvisited: See image.
Below, the user falls into a pit: See image.
Here is a mental model we can build (visited = green, unvisited = red). Again, there are likely more rows and more columns that we didnt visit. See image.
Below, the user is eaten by the Wumpus: See image.
Here is a mental model we can build (visited = green, unvisited = red). Again, there are likely more rows and more columns that we didnt visit. See image.
Below, the user kills the Wumpus, finds the gold, and exits: See image.
Here is a mental model we can build (visited = green, unvisited = red). Again, there are likely more rows and more columns that we didnt visit. See image.
This program should contain four classes (Person, Cell, Board, and Proj5). Your program must compile (by command-line) with the statement:
javac *.java
It must then run with the command:
java Proj5
The started files for each class are available in the proj5start.zip file on K-State Online. Note that the Person and Cell classes are finished you do not need to make changes to them. The Board and Proj5 classes list which methods you should have as well as what they should do. DO NOT remove those methods or modify their parameters or return values. If you do want to add additional methods, that is fine.
This section contains more details on requirements of the project:
The project has been documented for you. However, you should add your name under author at the top of those files. If you add any additional methods, you should add documentation for those methods as well.