Quote (thesnipa @ Aug 16 2021 02:37pm)
it appears each case i listed is returning rlvl 22, which afaik should be 24 instead.
example?
The full formula when parsing item packets and their children is this, but I cut that down for affixcalc cause it doesn't have all the variables an actual item has, like set or unique rarity.
Code
getLevelRequirement() {
var basereq = this.baseItem.levelreq, i, lvlreq, areq = 0,
areqs = [],
reqs = [basereq];
if (this.flags.Identified) {
switch (this.quality) {
case ItemQuality.Magic: // Affixes
if (this.prefix) areqs.push(MagicPrefix[this.prefix.index].levelreq || 0);
if (this.suffix) areqs.push(MagicSuffix[this.suffix.index].levelreq || 0);
if (this.autoMod) areqs.push(AutoAffix[this.autoMod].levelreq || 0);
break;
case ItemQuality.Rare:
if (this.autoMod) areqs.push(AutoAffix[this.autoMod].levelreq || 0);
break;
case ItemQuality.Set:
reqs.push(SetItem[this.setid].lvlreq || 0);
break;
case ItemQuality.Unique:
reqs.push(Unique[this.uniqueid].lvlreq || 0);
break;
}
if (this.magicPrefixes) {
for (i = 0; i < this.magicPrefixes.length; i++) {
areqs.push(MagicPrefix[this.magicPrefixes[i].index].levelreq);
}
}
if (this.magicSuffixes) {
for (i = 0; i < this.magicSuffixes.length; i++) {
areqs.push(MagicSuffix[this.magicSuffixes[i].index].levelreq);
}
}
areq = Math.max(...areqs);
if (this.quality === ItemQuality.Crafted) {
areq += 10;
if (this.magicPrefixes) areq += 3 * this.magicPrefixes.length;
if (this.magicSuffixes) areq += 3 * this.magicSuffixes.length;
}
reqs.push(areq);
}
reqs.push(this.singleskillreq || 0); // Staffmod level reqs
lvlreq = Math.max(...reqs);
if (this.dstats) lvlreq += this.dstats.itemlevelreq || 0; // When upped or double upped (+5 and +7 respectively, for a total of +12) socketed items are never upped, so no need to flatten stats
return Math.min(98, lvlreq);
}
You did mention +paladin skills, that just uses the same required level stuff from it being an affix (like any other) if the result isn't 24, then 24 isn't what it's supposed to be.
Staffmods are another thing
This post was edited by laztheripper on Aug 16 2021 01:33pm