Skip to content

Commit

Permalink
Partially revert 492a03a
Browse files Browse the repository at this point in the history
We need to remove excluded items we add in the last loop
  • Loading branch information
p3lim committed Jan 9, 2025
1 parent a40ea82 commit 2d69f28
Showing 1 changed file with 12 additions and 9 deletions.
21 changes: 12 additions & 9 deletions scripts/keys.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,20 +19,18 @@
if row.SpellID in effectSpells:
effects[row.ID] = row.SpellID

excluded = [
109645, # not available
]

items = {}
# iterate through the ItemXItemEffect dbc to match item effects to items
for row in itemXItemEffect:
if row.ItemEffectID in effects:
if not row.ItemID in excluded:
items[row.ItemID] = {
'itemID': row.ItemID,
'effectiveSkill': effectSpells[effects[row.ItemEffectID]]
}
items[row.ItemID] = {
'itemID': row.ItemID,
'effectiveSkill': effectSpells[effects[row.ItemEffectID]]
}

excluded = [
109645, # not available
]

# iterate through ItemSparse to fill in extra info
for row in itemSparse:
Expand All @@ -45,5 +43,10 @@
items[row.ID]['name'] = row.Display_lang
items[row.ID]['requiredLevel'] = row.RequiredLevel

# remove excluded items from the item list
for itemID in list(items):
if itemID in excluded:
del items[itemID]

# print data file structure
templateLuaTable('keys', '\t[{itemID}] = {{{effectiveSkill}, {requiredLevel}}}, -- {name}', items)

0 comments on commit 2d69f28

Please sign in to comment.