Skip to content

Commit 825eb6a

Browse files
committed
Also fix banned spell spheres/schools
1 parent 30c38f7 commit 825eb6a

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

MagicMaster/5.0.3/MagicMaster.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2024,7 +2024,7 @@ var MagicMaster = (function() { // eslint-disable-line no-unused-vars
20242024
bannedSpells = casterData.spb.dbName().split('|');
20252025

20262026
return _.reduce( (isMU ? school : sphere), (r,s) => {
2027-
banned = !(s === 'any' || ((isMU || majorSpells.includes('any') || majorSpells.some(sph => s.startsWith(sph)) || (minorSpells.some(sph => s.startsWith(sph)) && level < 4)) && (isPR || !bannedSpells.includes(s))));
2027+
banned = !(s === 'any' || ((isMU || majorSpells.includes('any') || majorSpells.some(sph => s.startsWith(sph)) || (minorSpells.some(sph => s.startsWith(sph)) && level < 4)) && (isPR || !bannedSpells.some(sph => s.startsWith(sph)))));
20282028
specialist = isMU && majorSpells.includes(s);
20292029
specStd = isMU && !majorSpells.includes('any');
20302030
return ((!allowAll && (!r || banned)) ? 0 : (specialist ? 3 : (specStd ? 2 : r)));

MagicMaster/MagicMaster.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2024,7 +2024,7 @@ var MagicMaster = (function() { // eslint-disable-line no-unused-vars
20242024
bannedSpells = casterData.spb.dbName().split('|');
20252025

20262026
return _.reduce( (isMU ? school : sphere), (r,s) => {
2027-
banned = !(s === 'any' || ((isMU || majorSpells.includes('any') || majorSpells.some(sph => s.startsWith(sph)) || (minorSpells.some(sph => s.startsWith(sph)) && level < 4)) && (isPR || !bannedSpells.includes(s))));
2027+
banned = !(s === 'any' || ((isMU || majorSpells.includes('any') || majorSpells.some(sph => s.startsWith(sph)) || (minorSpells.some(sph => s.startsWith(sph)) && level < 4)) && (isPR || !bannedSpells.some(sph => s.startsWith(sph)))));
20282028
specialist = isMU && majorSpells.includes(s);
20292029
specStd = isMU && !majorSpells.includes('any');
20302030
return ((!allowAll && (!r || banned)) ? 0 : (specialist ? 3 : (specStd ? 2 : r)));

MagicMaster/magicMaster.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2024,7 +2024,7 @@ var MagicMaster = (function() { // eslint-disable-line no-unused-vars
20242024
bannedSpells = casterData.spb.dbName().split('|');
20252025

20262026
return _.reduce( (isMU ? school : sphere), (r,s) => {
2027-
banned = !(s === 'any' || ((isMU || majorSpells.includes('any') || majorSpells.some(sph => s.startsWith(sph)) || (minorSpells.some(sph => s.startsWith(sph)) && level < 4)) && (isPR || !bannedSpells.includes(s))));
2027+
banned = !(s === 'any' || ((isMU || majorSpells.includes('any') || majorSpells.some(sph => s.startsWith(sph)) || (minorSpells.some(sph => s.startsWith(sph)) && level < 4)) && (isPR || !bannedSpells.some(sph => s.startsWith(sph)))));
20282028
specialist = isMU && majorSpells.includes(s);
20292029
specStd = isMU && !majorSpells.includes('any');
20302030
return ((!allowAll && (!r || banned)) ? 0 : (specialist ? 3 : (specStd ? 2 : r)));

0 commit comments

Comments
 (0)