Skip to content

Commit

Permalink
Added a buildMerchants method to the RPGame Class
Browse files Browse the repository at this point in the history
  • Loading branch information
Gavin Li committed Feb 20, 2015
1 parent de25901 commit 39e35d6
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
11 changes: 11 additions & 0 deletions MerchantRPGCSE2102/src/controller/RPGame.java
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,17 @@ else if (currentMerchant == 3)

}

/**
* Generates all three merchants
* will add them to the map, but function is not written yet
*/
public void buildMerchants()
{
_merchant1 = new Merchant("Merchant 1", 1000, merchantInventoryList1);
_merchant2 = new Merchant("Merchant 2", 1000, merchantInventoryList2);
_merchant3 = new Merchant("Merchant 3", 1000, merchantInventoryList3);
}

/**
* This method returns the specified merchant inventory list
*
Expand Down
4 changes: 0 additions & 4 deletions MerchantRPGCSE2102/src/model/Player.java
Original file line number Diff line number Diff line change
Expand Up @@ -85,14 +85,10 @@ public boolean sell(String itemName, Merchant targetMerchant, int amount)
return true;
}
else
{
return false;
}
}
else
{
return false;
}
}

/**
Expand Down

0 comments on commit 39e35d6

Please sign in to comment.