added a removeRiddler() method.

This commit is contained in:
Luca Carnegie
2019-05-30 23:41:20 -04:00
parent 38a10f116d
commit 0da2e95425
3 changed files with 10 additions and 4 deletions

View File

@@ -385,7 +385,7 @@ class Game {
if(player.addToInventory(prize)) {
player.addToInventory(prize);
System.out.println("A " + prizeName + " has been added to your inventory.");
currentRoom.riddler = null;
currentRoom.removeRiddler();
System.out.println("I've got to go find Mr. Pellatt now. Good luck with your escape!");
}else {
System.out.println("Sorry, you can't carry any more ");
@@ -543,6 +543,7 @@ class Game {
return false;
}
// implementations of user commands:
/**
* Print out some help information. Here we print some stupid, cryptic