From 518af81d22557f333fdd21b62443ce287f52cc7c Mon Sep 17 00:00:00 2001 From: hppeng Date: Thu, 15 Sep 2022 22:54:36 -0700 Subject: [PATCH] HOTFIX: Fix item set association more robust/future proof sets info, at the cost of some load time --- js/load.js | 5 +++++ py_script/items_common.py | 10 ++++++++++ 2 files changed, 15 insertions(+) diff --git a/js/load.js b/js/load.js index 0091eb1..1d78206 100644 --- a/js/load.js +++ b/js/load.js @@ -254,4 +254,9 @@ function init_maps() { redirectMap.set(item.id, item.remapID); } } + for (const [set_name, set_data] of sets) { + for (const item_name of set_data.items) { + itemMap.get(item_name).set = set_name; + } + } } diff --git a/py_script/items_common.py b/py_script/items_common.py index 23527c0..4541722 100644 --- a/py_script/items_common.py +++ b/py_script/items_common.py @@ -36,8 +36,18 @@ translate_mappings = { "manaRegen": "mr", #"spellDamage": "sdPct", "spellDamageBonus": "sdPct", + "spellFireDamageBonus": "fSdPct", + "spellWaterDamageBonus": "wSdPct", + "spellAirDamageBonus": "aSdPct", + "spellThunderDamageBonus": "tSdPct", + "spellEarthDamageBonus": "eSdPct", #"damageBonus": "mdPct", "mainAttackDamageBonus": "mdPct", + "mainAttackFireDamageBonus": "fMdPct", + "mainAttackWaterDamageBonus": "wMdPct", + "mainAttackAirDamageBonus": "aMdPct", + "mainAttackThunderDamageBonus": "tMdPct", + "mainAttackEarthDamageBonus": "eMdPct", "lifeSteal": "ls", "manaSteal": "ms", "xpBonus": "xpb",