Browse Source

Remove duplicate of getProto()

Sam Jaffe 8 năm trước cách đây
mục cha
commit
23b474aa96

+ 2 - 2
src/main/lombok/org/leumasjaffe/charsheet/model/DDCharacterClass.java

@@ -25,7 +25,7 @@ import lombok.experimental.FieldDefaults;
 @FieldDefaults(level=AccessLevel.PRIVATE, makeFinal=true)
 public class DDCharacterClass extends Observable implements Comparable<DDCharacterClass>, Cloneable {
 	private static final class Reference {
-		@Getter DDClass base;
+		DDClass base;
 		
 		public boolean equals(Object o) {
 			return this == o || base.equals(o);
@@ -57,7 +57,7 @@ public class DDCharacterClass extends Observable implements Comparable<DDCharact
 	public DDCharacterClass(String name) {
 		this.level = new IntValue(0);
 		this.name = new Reference(name);
-		this.spellBook = getBase().createNewSpellBook();
+		this.spellBook = getProto().createNewSpellBook();
 	}
 	
 	public String toString() {

+ 1 - 1
src/main/lombok/org/leumasjaffe/charsheet/view/level/LevelUpSpellPanel.java

@@ -43,7 +43,7 @@ class LevelUpSpellPanel extends JPanel {
 			}
 			@Override
 			public Collection<DDSpell> getAvailableSpells(Info info, int i) {
-				Collection<DDSpell> spells = new ArrayList<>(info.dclass.getBase().getSpellList(i));
+				Collection<DDSpell> spells = new ArrayList<>(info.dclass.getProto().getSpellList(i));
 				spells.removeAll(info.dclass.getSpellBook().get().spellsKnownAtLevel(i));
 				return spells;
 			}

+ 1 - 1
src/main/lombok/org/leumasjaffe/charsheet/view/level/UpdateClassWithLevelPanel.java

@@ -73,7 +73,7 @@ class UpdateClassWithLevelPanel extends JPanel {
 		add(tabbedPane, gbc_tabbedPane);
 
 		JPanel features = new JPanel(new VerticalLayout(2));
-		info.ddClass.getBase().getFeatures(info.toLevel).forEach(prop -> {
+		info.ddClass.getProto().getFeatures(info.toLevel).forEach(prop -> {
 			features.add(new JLabel(prop.getName()));
 		});
 		tabbedPane.addTab("Features", null, features, null);