-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Gavin Li
committed
Feb 2, 2015
1 parent
2ba157f
commit dc693ce
Showing
2 changed files
with
27 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package game; | ||
|
||
public class Player | ||
{ | ||
private String _name; | ||
private int _playerCash; | ||
private Item[] _playerInventory; | ||
|
||
//constructor | ||
public Player(String playerName, int startingCash, int startingInventory) | ||
{ | ||
_name = playerName; | ||
_playerCash = startingCash; | ||
_playerInventory = new Item[startingInventory]; | ||
} | ||
|
||
//Buy method, allows player to gain new items | ||
//deducts cash based on the price of item | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
package tests; | ||
|
||
import game.Player; | ||
|
||
public class TestPlayer | ||
{ | ||
|
||
} |