debugging

This commit is contained in:
Joshua-Ashton01
2022-11-08 19:57:07 -07:00
parent a474d5d43b
commit 048b7a342f
21 changed files with 324 additions and 51 deletions
@@ -1,4 +1,5 @@
package Character;
package Character.AbilityScores;
public class CharacterStats {
private Stats[] stats;
@@ -48,13 +49,13 @@ public class CharacterStats {
*
* Allows for access to a particular stat.
*
* @param int stat
* @param index
* @return a specific stat
*
*/
public Stats getStats(int stat) {
public Stats getStats(int index) {
return stats[stat];
return stats[index];
}
@@ -46,7 +46,7 @@ public class Charisma extends Stats {
}
@Override
void increaseScore() {
public void increaseScore() {
abilityScore++;
@@ -46,7 +46,7 @@ public class Constitution extends Stats {
}
@Override
void increaseScore() {
public void increaseScore() {
abilityScore++;
@@ -46,7 +46,7 @@ public class Dexterity extends Stats {
}
@Override
void increaseScore() {
public void increaseScore() {
abilityScore++;
@@ -46,7 +46,7 @@ public class Intelligence extends Stats{
}
@Override
void increaseScore() {
public void increaseScore() {
abilityScore++;
@@ -37,13 +37,13 @@ public abstract class Stats {
case 20:
return 5;
default:
return 0;
return -42;
}
}
abstract void increaseScore();
public abstract void increaseScore();
abstract int getScore();
@@ -58,7 +58,7 @@ public class Strength extends Stats {
}
@Override
void increaseScore() {
public void increaseScore() {
abilityScore++;
@@ -46,7 +46,7 @@ public class Wisdom extends Stats {
}
@Override
void increaseScore() {
public void increaseScore() {
abilityScore++;
-1
View File
@@ -13,7 +13,6 @@ public class Background {
/**
* @param name
* @param skillProficiences
* @param feature
*/
public Background(String name, boolean[] proficientStatus, String[] skills, String feature) {
@@ -1,5 +1,6 @@
package Character;
import Character.AbilityScores.CharacterStats;
import Character.Races.*;
import java.io.Serializable;
+4 -2
View File
@@ -1,5 +1,7 @@
package Character;
import Character.AbilityScores.*;
/**
*
* Object stores information about a character's skills arrays. Firstly, the name of each skill, and secondly the value of each skill. When constructed, a private method is called
@@ -23,8 +25,8 @@ public class Skills {
*
* Default constructor for the Skills class. Should be constructed AFTER the user has generated their stats and chosen the skills they are proficient in.
*
* @param int[] skills
* @param Stats[] stats
* @param skills
* @param stats
*
*/
public Skills(int[] skills, Stats[] stats) {