Read item skill requirements from the cache template
validForSkills, isShield, the guard attack rating and the NPC vendor skill filter read getItemSkillReq. Offline parity (p15d.py, 7586 rows): 0 differences. No template lists "Cloth" in item_skill_req and none has more than one entry, so file order vs HashMap order is moot. Value changes: none. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
5b3c511b55
commit
7abc63ffc3
3 files changed
+9
-9
No files matched your search
@@ -966,8 +966,8 @@ public class NPC extends AbstractCharacter {
|
||||
for (Integer itemID : fullItemList) {
|
||||
itemTemplate = ItemTemplate.templates.get(itemID);
|
||||
|
||||
if (itemTemplate.item_skill_required.values().iterator().hasNext())
|
||||
skillRequired = itemTemplate.item_skill_required.values().iterator().next();
|
||||
if (itemTemplate.cacheTemplate.getItemSkillReq().values().iterator().hasNext())
|
||||
skillRequired = itemTemplate.cacheTemplate.getItemSkillReq().values().iterator().next();
|
||||
|
||||
boolean exclude = skillRequired == 0 && ItemTemplate.templates.get(itemID).cacheTemplate.getItemType().equals(ItemType.WEAPON);
|
||||
if (skillRequired <= maxSkill && !exclude)
|
||||
|
||||
Reference in new issue
Block a user