diff --git a/ADnD_2E_Revised/2ESheet.html b/ADnD_2E_Revised/2ESheet.html
index 85f505f420..278d8033ac 100644
--- a/ADnD_2E_Revised/2ESheet.html
+++ b/ADnD_2E_Revised/2ESheet.html
@@ -3904,7 +3904,7 @@
Level
Specialist
- Intelligence
+ Intelligence
Total
|
Remaining
@@ -3914,7 +3914,7 @@
-
+
|
@@ -8739,7 +8739,7 @@
Level
- Wisdom
+ Wisdom
Total
|
Remaining
@@ -8748,11 +8748,16 @@
Spell Points
+
|
+
+ Bonus spell points from high Wisdom to Priests
+ Priests with high Wisdom scores gain a special bonus spell points to reflect their piety and devotion. (This is a standard rule in this spell point system, unlike the optional bonus spell point rule for wizards with high Intelligence scores.) PO: Spells & Powers, p. 92
+
@@ -33732,16 +33737,16 @@ intelligenceTable['intimm4th'] = ['Error','','','','','','','','','','','','',''
intelligenceTable['intimm5th'] = ['Error','','','','','','','','','','','','','','','','','','','','','','','5th-level','5th-level','5th-level'];
intelligenceTable['intimm6th'] = ['Error','','','','','','','','','','','','','','','','','','','','','','','','6th-level','6th-level'];
intelligenceTable['intimm7th'] = ['Error','','','','','','','','','','','','','','','','','','','','','','','','','7th-level'];
-intelligenceTable['spell-points-int'] = [0,0,0,0,0,0,0,0,0,2,2,2,3,3,4,4,5,6,7,8,9,9,9,9,9,9];
intelligenceTable['intnotes'] = ['INVALID INTELLIGENCE','Communicate by Grunts & Gestures','','','','','','','','','','','','','','','','','','','','','','','','',''];
+intelligenceTable['spell-points-int'] = [0,0,0,0,0,0,0,0,0,2,2,2,3,3,4,4,5,6,7,8,9,9,9,9,9,9];
const wisdomTable = {};
wisdomTable['wisdef'] = ['Error','-6','-4','-3','-2','-1','-1','-1','0','0','0','0','0','0','0','+1','+2','+3','+4','+4','+4','+4','+4','+4','+4','+4'];
wisdomTable['wisbonus'] = ['Error','—','—','—','—','—','—','—','—','0','0','0','0','1st','1st','2nd','2nd','3rd','4th','1st,3rd','2nd,4th','3rd,5th','4th,5th','1st,6th','5th,6th','6th,7th'];
-wisdomTable['wisdom-wind'] = [0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,2,2,3,4,5,6,7,8,9,10,11,12];
wisdomTable['wisfail'] = ['Error','80','60','50','45','40','35','30','25','20','15','10','5','0','0','0','0','0','0','0','0','0','0','0','0','0'];
wisdomTable['wisimmune'] = ['Error','','','','','','','','','','','','','','','','','','','cause fear, charm person, command, friends, hypnotism','forget, hold person, ray of enfeeblement, scare','fear','charm monster, confusion, emotion, fumble, suggestion','chaos, feeblemind, hold monster, magic jar, quest','geas, mass suggestion, rod of rulership','antipathy/sympathy, death spell, mass charm'];
wisdomTable['wisnotes'] = ['INVALID WISDOM','','','','','','','','','','','','','','','','','','','','','','','','','',''];
+wisdomTable['wisdom-wind'] = [0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,2,2,3,4,5,6,7,8,9,10,11,12];
const charismaTable = {};
charismaTable['chamax'] = ['Error','0','1','1','1','2','2','3','3','4','4','4','5','5','6','7','8','10','15','20','25','30','35','40','45','50'];
@@ -69818,7 +69823,7 @@ on('change:spell-points-int-enabled change:intelligence', function (eventInfo) {
getAttrs(['spell-points-int-enabled', 'intelligence'], function (values) {
let newValue = {'spell-points-int': 0}
if (values['spell-points-int-enabled'] !== '1') {
- return setAttrs(newValue)
+ return setAttrs(newValue);
}
let intelligence = getLookupValue(values['intelligence'], 0);
newValue['spell-points-int'] = intelligenceTable['spell-points-int'][intelligence];
@@ -69835,6 +69840,70 @@ setupRepeatingSpellSumming(allPriestSpellSections, priestSpellPoints, 'spell-poi
setupRepeatingSpellSumming(allPriestSpellSections, 'wind', 'spell-wind', `${wind}-sum`, true);
setupCalculateRemaining(`${priestSpellPoints}-total`, `${priestSpellPoints}-sum`, `${priestSpellPoints}-remaining`);
setupCalculateRemaining(wind, `${wind}-sum`, `${wind}-remaining`);
+let PRIEST_SPELL_POINTS_WIS = 'spell-points-priest-wis';
+on('change:spell-points-priest-wis-enabled change:wisdom change:level-priest', function (eventInfo) {
+ getAttrs(['spell-points-priest-wis-enabled', 'wisdom', 'level-priest'], async function (values) {
+ await keepContextRoll();
+ let newValue = {};
+ newValue[PRIEST_SPELL_POINTS_WIS] = 0;
+ if (values['spell-points-priest-wis-enabled'] !== '1') {
+ return setAttrs(newValue);
+ }
+ let wisdom = getLookupValue(values['wisdom'], 0);
+ if (wisdom < 13) {
+ return setAttrs(newValue);
+ }
+ if (wisdom === 13) {
+ newValue[PRIEST_SPELL_POINTS_WIS] = 4;
+ return setAttrs(newValue);
+ }
+ if (wisdom === 14) {
+ newValue[PRIEST_SPELL_POINTS_WIS] = 8;
+ return setAttrs(newValue);
+ }
+ let level = await extractRollResult(values['level-priest']);
+ if (isNaN(level) || level < 0) {
+ level = 1;
+ }
+ let spellPoints = 0;
+ if (wisdom === 15) {
+ spellPoints = level < 3 ? 8 : 15;
+ } else if (wisdom === 16) {
+ spellPoints = level < 3 ? 8 : 20;
+ } else if (wisdom === 17) {
+ if (1 <= level && level <= 2) {
+ spellPoints = 8;
+ } else if (3 <= level && level <= 4) {
+ spellPoints = 20;
+ } else {
+ spellPoints = 30;
+ }
+ } else if (wisdom === 18) {
+ if (1 <= level && level <= 2) {
+ spellPoints = 8;
+ } else if (3 <= level && level <= 4) {
+ spellPoints = 20;
+ } else if (5 <= level && level <= 6) {
+ spellPoints = 30;
+ } else {
+ spellPoints = 45;
+ }
+ } else if (wisdom >= 19) {
+ if (1 <= level && level <= 2) {
+ spellPoints = 12;
+ } else if (3 <= level && level <= 4) {
+ spellPoints = 25;
+ } else if (5 <= level && level <= 6) {
+ spellPoints = 45;
+ } else {
+ spellPoints = 60;
+ }
+ }
+
+ newValue[PRIEST_SPELL_POINTS_WIS] = spellPoints;
+ setAttrs(newValue);
+ });
+});
// --- End setup Spell Points, Arc, and Wind --- //
// --- Start setup reset buttons --- //
diff --git a/ADnD_2E_Revised/html/changelog.html b/ADnD_2E_Revised/html/changelog.html
index 441c7fa495..82b42a449d 100644
--- a/ADnD_2E_Revised/html/changelog.html
+++ b/ADnD_2E_Revised/html/changelog.html
@@ -13,10 +13,10 @@
Added Spell tracking selection to the Sheet Settings Tab. Choices are: Spell slots, spell points, Arcs / Winds
Redesigned the Spells tab to only show the spell tracking system that selected on the Sheet Settings Tab
High Wisdom now triggers a popup asking if you are a priest. Bonus spells are only added if you are a priest
- High Wisdom now autofill bonus Winds for Priests for the Arcs/Winds spell tracking system. If the PO: S&P sub ability scores are used, base Wisdom is still used for determining bonus winds
- Added support for automatic Spell Points for Wizards with high Intelligence
- High Constitution Regeneration now clarifies that it is per turn(s)
- Fixed bonus spells from high Intuition. Willpower was incorrectly used
+ High Wisdom now autofill bonus Winds for Priests for the Arcs/Winds spell tracking system, based on the same popup as stated above. If the PO: S&P sub ability scores are used, base Wisdom is still used for determining bonus winds
+ Added support for automatic Spell Points for Wizards with high Intelligence. This is a toggle as the bonus is optional.
+ Added support for automatic Spell Points for Priests with high Wisdom. This is a toggle as only priests gets this bonus, and not Paladins and rangers. The Priest caster level is used to determine how many spell points should be given
+ Fixed bonus spells from high Intuition from PO: Skills & Powers. Willpower was incorrectly used
Styled Monster tab to have dynamically sized fields, and larger fields for Hit Dice, HP, and Max HP
2Espell - Sensory signature and Knockdown switched places to make them appear in the same order as in the PO: Spells & Magic book
diff --git a/ADnD_2E_Revised/html/tabs/character-tab/spells-tab/priest-tab.html b/ADnD_2E_Revised/html/tabs/character-tab/spells-tab/priest-tab.html
index eb78c07de6..2d26714ba8 100644
--- a/ADnD_2E_Revised/html/tabs/character-tab/spells-tab/priest-tab.html
+++ b/ADnD_2E_Revised/html/tabs/character-tab/spells-tab/priest-tab.html
@@ -46,7 +46,7 @@
Level
- Wisdom
+ Wisdom
Total
|
Remaining
@@ -55,11 +55,16 @@
Spell Points
+
|
+
+ Bonus spell points from high Wisdom to Priests
+ Priests with high Wisdom scores gain a special bonus spell points to reflect their piety and devotion. (This is a standard rule in this spell point system, unlike the optional bonus spell point rule for wizards with high Intelligence scores.) PO: Spells & Powers, p. 92
+
diff --git a/ADnD_2E_Revised/html/tabs/character-tab/spells-tab/wizard-tab.html b/ADnD_2E_Revised/html/tabs/character-tab/spells-tab/wizard-tab.html
index b240705946..685c6424cc 100644
--- a/ADnD_2E_Revised/html/tabs/character-tab/spells-tab/wizard-tab.html
+++ b/ADnD_2E_Revised/html/tabs/character-tab/spells-tab/wizard-tab.html
@@ -34,7 +34,7 @@
Level
Specialist
- Intelligence
+ Intelligence
Total
|
Remaining
@@ -44,7 +44,7 @@
-
+
|
diff --git a/ADnD_2E_Revised/javascript/abilityScores.js b/ADnD_2E_Revised/javascript/abilityScores.js
index 30f09d49f9..4a9fc1bc57 100644
--- a/ADnD_2E_Revised/javascript/abilityScores.js
+++ b/ADnD_2E_Revised/javascript/abilityScores.js
@@ -99,16 +99,16 @@ intelligenceTable['intimm4th'] = ['Error','','','','','','','','','','','','',''
intelligenceTable['intimm5th'] = ['Error','','','','','','','','','','','','','','','','','','','','','','','5th-level','5th-level','5th-level'];
intelligenceTable['intimm6th'] = ['Error','','','','','','','','','','','','','','','','','','','','','','','','6th-level','6th-level'];
intelligenceTable['intimm7th'] = ['Error','','','','','','','','','','','','','','','','','','','','','','','','','7th-level'];
-intelligenceTable['spell-points-int'] = [0,0,0,0,0,0,0,0,0,2,2,2,3,3,4,4,5,6,7,8,9,9,9,9,9,9];
intelligenceTable['intnotes'] = ['INVALID INTELLIGENCE','Communicate by Grunts & Gestures','','','','','','','','','','','','','','','','','','','','','','','','',''];
+intelligenceTable['spell-points-int'] = [0,0,0,0,0,0,0,0,0,2,2,2,3,3,4,4,5,6,7,8,9,9,9,9,9,9];
const wisdomTable = {};
wisdomTable['wisdef'] = ['Error','-6','-4','-3','-2','-1','-1','-1','0','0','0','0','0','0','0','+1','+2','+3','+4','+4','+4','+4','+4','+4','+4','+4'];
wisdomTable['wisbonus'] = ['Error','—','—','—','—','—','—','—','—','0','0','0','0','1st','1st','2nd','2nd','3rd','4th','1st,3rd','2nd,4th','3rd,5th','4th,5th','1st,6th','5th,6th','6th,7th'];
-wisdomTable['wisdom-wind'] = [0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,2,2,3,4,5,6,7,8,9,10,11,12];
wisdomTable['wisfail'] = ['Error','80','60','50','45','40','35','30','25','20','15','10','5','0','0','0','0','0','0','0','0','0','0','0','0','0'];
wisdomTable['wisimmune'] = ['Error','','','','','','','','','','','','','','','','','','','cause fear, charm person, command, friends, hypnotism','forget, hold person, ray of enfeeblement, scare','fear','charm monster, confusion, emotion, fumble, suggestion','chaos, feeblemind, hold monster, magic jar, quest','geas, mass suggestion, rod of rulership','antipathy/sympathy, death spell, mass charm'];
wisdomTable['wisnotes'] = ['INVALID WISDOM','','','','','','','','','','','','','','','','','','','','','','','','','',''];
+wisdomTable['wisdom-wind'] = [0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,2,2,3,4,5,6,7,8,9,10,11,12];
const charismaTable = {};
charismaTable['chamax'] = ['Error','0','1','1','1','2','2','3','3','4','4','4','5','5','6','7','8','10','15','20','25','30','35','40','45','50'];
diff --git a/ADnD_2E_Revised/javascript/sheetWorkers.js b/ADnD_2E_Revised/javascript/sheetWorkers.js
index d02523196f..045112609e 100644
--- a/ADnD_2E_Revised/javascript/sheetWorkers.js
+++ b/ADnD_2E_Revised/javascript/sheetWorkers.js
@@ -1327,7 +1327,7 @@ on('change:spell-points-int-enabled change:intelligence', function (eventInfo) {
getAttrs(['spell-points-int-enabled', 'intelligence'], function (values) {
let newValue = {'spell-points-int': 0}
if (values['spell-points-int-enabled'] !== '1') {
- return setAttrs(newValue)
+ return setAttrs(newValue);
}
let intelligence = getLookupValue(values['intelligence'], 0);
newValue['spell-points-int'] = intelligenceTable['spell-points-int'][intelligence];
@@ -1344,6 +1344,70 @@ setupRepeatingSpellSumming(allPriestSpellSections, priestSpellPoints, 'spell-poi
setupRepeatingSpellSumming(allPriestSpellSections, 'wind', 'spell-wind', `${wind}-sum`, true);
setupCalculateRemaining(`${priestSpellPoints}-total`, `${priestSpellPoints}-sum`, `${priestSpellPoints}-remaining`);
setupCalculateRemaining(wind, `${wind}-sum`, `${wind}-remaining`);
+let PRIEST_SPELL_POINTS_WIS = 'spell-points-priest-wis';
+on('change:spell-points-priest-wis-enabled change:wisdom change:level-priest', function (eventInfo) {
+ getAttrs(['spell-points-priest-wis-enabled', 'wisdom', 'level-priest'], async function (values) {
+ await keepContextRoll();
+ let newValue = {};
+ newValue[PRIEST_SPELL_POINTS_WIS] = 0;
+ if (values['spell-points-priest-wis-enabled'] !== '1') {
+ return setAttrs(newValue);
+ }
+ let wisdom = getLookupValue(values['wisdom'], 0);
+ if (wisdom < 13) {
+ return setAttrs(newValue);
+ }
+ if (wisdom === 13) {
+ newValue[PRIEST_SPELL_POINTS_WIS] = 4;
+ return setAttrs(newValue);
+ }
+ if (wisdom === 14) {
+ newValue[PRIEST_SPELL_POINTS_WIS] = 8;
+ return setAttrs(newValue);
+ }
+ let level = await extractRollResult(values['level-priest']);
+ if (isNaN(level) || level < 0) {
+ level = 1;
+ }
+ let spellPoints = 0;
+ if (wisdom === 15) {
+ spellPoints = level < 3 ? 8 : 15;
+ } else if (wisdom === 16) {
+ spellPoints = level < 3 ? 8 : 20;
+ } else if (wisdom === 17) {
+ if (1 <= level && level <= 2) {
+ spellPoints = 8;
+ } else if (3 <= level && level <= 4) {
+ spellPoints = 20;
+ } else {
+ spellPoints = 30;
+ }
+ } else if (wisdom === 18) {
+ if (1 <= level && level <= 2) {
+ spellPoints = 8;
+ } else if (3 <= level && level <= 4) {
+ spellPoints = 20;
+ } else if (5 <= level && level <= 6) {
+ spellPoints = 30;
+ } else {
+ spellPoints = 45;
+ }
+ } else if (wisdom >= 19) {
+ if (1 <= level && level <= 2) {
+ spellPoints = 12;
+ } else if (3 <= level && level <= 4) {
+ spellPoints = 25;
+ } else if (5 <= level && level <= 6) {
+ spellPoints = 45;
+ } else {
+ spellPoints = 60;
+ }
+ }
+
+ newValue[PRIEST_SPELL_POINTS_WIS] = spellPoints;
+ setAttrs(newValue);
+ });
+});
// --- End setup Spell Points, Arc, and Wind --- //
// --- Start setup reset buttons --- //