Redid a bunch of commenting making sure that every method was commented.
This commit is contained in:
@@ -1,8 +1,10 @@
|
||||
package logic;
|
||||
|
||||
public class GameEndLogic extends Player{
|
||||
|
||||
/**
|
||||
* Calculates the networth of the player by the end of the game
|
||||
* Calculates the networth of the player by the end of the game.
|
||||
* Calculation is based off the total guns and items bought throughout the game
|
||||
* @return the total networth of the player
|
||||
*/
|
||||
public int getNetWorth() {
|
||||
@@ -24,4 +26,13 @@ public class GameEndLogic extends Player{
|
||||
return "Congratulations!";
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* A method that creates an array filled will all the user's stats
|
||||
* @param netWorthInt the total net worth of the user
|
||||
* @return Returns the firm name of the user, the guns they held and their total net worth
|
||||
*/
|
||||
public String[] endGameStats(int netWorthInt) {
|
||||
return new String[]{"Firm Name: " + getName(), "Guns Held: " + getGuns(), "Net Worth: " + netWorthInt};
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user