made abstract

This commit is contained in:
Joshua Perry 2023-01-31 16:00:09 +00:00
parent 3d27875286
commit 6dc8dc4bdd
1 changed files with 2 additions and 10 deletions

View File

@ -1,13 +1,11 @@
package org.r0r5chach; package org.r0r5chach;
import java.text.DecimalFormat; import java.text.DecimalFormat;
import java.util.Arrays;
/** /**
* Class that defines the various attributes and methods associated with a Valorant Player * Class that defines the various attributes and methods associated with a Valorant Player
* @author r0r5chach * @author r0r5chach
*/ */
public class Competitor { public abstract class Competitor {
/** /**
* The format to use when converting decimal numbers to strings * The format to use when converting decimal numbers to strings
*/ */
@ -117,13 +115,7 @@ public class Competitor {
* Get all the attributes of the player * Get all the attributes of the player
* @return all attributes of the player in a formatted string * @return all attributes of the player in a formatted string
*/ */
public String getFullDetails() { public abstract String getFullDetails();
return "Player Number: " + getPlayerNumber() +
"\nName: " + getPlayerName().getFullName() +
"\nPlayer Level: " + getPlayerLevel().getRank() +
"\nScores: " + Arrays.toString(getScores()).replace("[","").replace("]", "") + //replace() allows the array to not be surrounded by brackets
"\nOverall Score: " + getOverallScore();
}
/** /**
* Get the important attributes of the player * Get the important attributes of the player
* @return a formatted string containing the playerNumber, playerName, and overall score * @return a formatted string containing the playerNumber, playerName, and overall score