finalize repeating classes

This commit is contained in:
Mark
2016-02-05 15:56:21 +01:00
parent f063ec87e3
commit fe3208ee40
@@ -324,13 +324,14 @@ var updateLevels = function () {
var classHd = v[repeatingString + 'hd'];
console.log('classHd', classHd);
if (!exists(classHd)) {
if (!exists(classHd)) {
if (defaultClassDetails.hasOwnProperty(className)) {
classHd = defaultClassDetails[className].hd;
finalSetAttrs[repeatingString + 'hd'] = classHd;
} else {
classHd = 'd0';
}
}
}
hd[classHd] += classLevel;
var classSpellcasting = v[repeatingString + 'spellcasting'];
@@ -338,6 +339,7 @@ var updateLevels = function () {
if (!exists(classSpellcasting)) {
if (defaultClassDetails.hasOwnProperty(className)) {
classSpellcasting = defaultClassDetails[className].spellcasting;
finalSetAttrs[repeatingString + 'spellcasting'] = classSpellcasting;
}
}
if (exists(classSpellcasting)) {
@@ -415,6 +417,7 @@ var updateSpellSlots = function () {
var finalSetAttrs = {};
var spellSlotTiers = {
0: {},
1: {
1: 2
},