BlueJ Text Adventure Game

Completed Posted Mar 18, 2012 Paid on delivery
Completed Paid on delivery

Overview:

My project requires someone to add additional parts to a BlueJ project. It must be implemented in a manner consistent with the class design techniques (coupling, cohesion, and refactoring). All new methods and new classes must be commented well.

Project Structre:

Five BlueJ projects need to be produced. What goes into each project is made clear with each requirement below.

The naming conversion for each project is:

Zuul-Better 1.10

Zuul-Better 1.11

Zuul-Better 1.12

Zuul-Better 1.13

Zuul-Better 1.14

Task 1:

Project name 1.10

Add a main method to the Game class which constructs a new Game object and calls its play() method. In other words, the application must be executable outside of the BlueJ environment.

The 1.10 version and all subsequent versions should be executable outside of BlueJ.

Task 2:

Project Name 1.11

Create a method called display() in the Game class with a single String parameter, which handles all output to the terminal window produced by the Game class.

Implement the display() method so it prints to the terminal window only if a boolean field in the Game class (e.g. ‘debug_mode’) is not true. This will be used when unit testing the Game class.

Include a look command, which re-displays a description of the current room and its contents.

Task 3:

Project Name 1.12

Allow a single item to be added to a room. Each item has a name, a description, and a weight. The description displayed when a player enters a room, should include the name and weight of the item located in the room.

Implement a new command examine, followed by the name of an item that exists in the room you are in.

Task 4:

Project Name 1.13

Allow a room to hold an unlimited number of items. Any actions that resulted in a description of the room contents, should now describe all of the items in that room.

Implement a back command, so that using it repeatedly takes you back several rooms.

Create a TestGame class which includes a method called testBack() designed to test the operation of the ‘back’ command. The method should display to the terminal window:

· The test that is running,

· The results of the test (whether it failed or not).

You may need to add some public methods in your Game class so that you are able to invoke them from your test class e.g. the private method:

private boolean processCommand(Command command)

{…}

could be accessed from the test class, via a new public method:

public boolean testProcessCommand(Command command)

{

return processCommand(command);

}

This approach would avoid changing the existing access modifiers from private to public. The newly added section of test methods could then be commented out, or removed from your final version. Be sure to comment any test methods you add.

To stop interference with the test results, the method should disable printing by the Game class (see task 2).

Task 5:

Project Name 1.14

Re-factor version 1.4 to introduce a separate Player class. This class includes fields and methods to maintain the state of the current room the player is in, as well as the previous rooms this player visited.

When starting the game, a list of players is entered from the command line. During execution of the game, the act of switching players changes the context of the game so it matches that of the required player e.g. If ‘Tracey’ is the current player and is in the theatre just before the player is switched, the location changes to that next player’s last location, or the outside, if this is the new players’ first go. When ‘Tracey’ becomes the current player again, the context reverts back to the theatre. In other words, each player will have their own room history.

Implement 3 new commands:

· take,

· drop,

· inventory.

Take allows the player to pick up an item found the room, drop command allows the player to place a previously taken item into the room they are in.

Inventory displays a list of items the player is carrying, along with the weight of each item.

Java

Project ID: #1511706

About the project

4 proposals Remote project Active Mar 22, 2012

Awarded to:

dobreiiita

Hi, I am JAVA expert and can surely satisfy you with my expertise. Please check your inbox,Thanks

$100 USD in 2 days
(157 Reviews)
6.3

4 freelancers are bidding on average $60 for this job

rakib062

Hi, I am a graduate in CS and working as a Java programmer. I have clear and concise OOP concepts. I already did project in bluej for an adventure game, please refer to my previous works to get idea. I assure you of s More

$50 USD in 1 day
(7 Reviews)
3.7
Sahil5287

I have 3 year of Java Devlopment experience and I am Oracle Certified Java Programmer. Quite an easy task for me. Please check PM for more details

$60 USD in 2 days
(0 Reviews)
0.0
abdulmohsin

I'm an expert Java/JavaEE programmer associated with top 20 fortune IT companies from last 8 years. I'm sure I can deliver these changes within the timelines. Thanks, Abdul

$30 USD in 4 days
(0 Reviews)
0.0