Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

修复 #87 #91

Merged
merged 1 commit into from
Oct 5, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions app/lol/connector.py
Original file line number Diff line number Diff line change
Expand Up @@ -517,6 +517,16 @@ def __patch(self, path, data=None):


class JsonManager:

# 曾经奥恩可以升级的杰作装备
masterpieceItemsMap = {
7003: 6664, # 涡轮炼金罐
7004: 3068, # 日炎圣盾
7007: 6672, # 海妖杀手
7008: 6673, # 不朽盾弓
7022: 4005, # 帝国指令
}

def __init__(self, itemData, spellData, runeData, queueData, champions, skins):
self.items = {item["id"]: item["iconPath"] for item in itemData}
self.spells = {item["id"]: item["iconPath"] for item in spellData[:-3]}
Expand All @@ -537,6 +547,9 @@ def __init__(self, itemData, spellData, runeData, queueData, champions, skins):
]["skins"][item["name"]] = item["id"]
self.champions[champs[championId]]["id"] = championId

for oldId, nowId in JsonManager.masterpieceItemsMap.items():
self.items[oldId] = self.items[nowId]

def getItemIconPath(self, iconId):
if iconId != 0:
return self.items[iconId]
Expand Down