aboutsummaryrefslogtreecommitdiff
path: root/make_table.py
diff options
context:
space:
mode:
authorDaniel Schadt <kingdread@gmx.de>2019-12-10 14:17:54 +0100
committerDaniel Schadt <kingdread@gmx.de>2019-12-10 14:17:54 +0100
commit0c9276482d1508480ca247183853a31b762d25cf (patch)
tree49248d34082ed6b3db0bab21a20cc48f5803898a /make_table.py
parent8212e56fd470985bcb5dca94defc40854fb95894 (diff)
downloadkondou-0c9276482d1508480ca247183853a31b762d25cf.tar.gz
kondou-0c9276482d1508480ca247183853a31b762d25cf.tar.bz2
kondou-0c9276482d1508480ca247183853a31b762d25cf.zip
make skill lookup table static
Diffstat (limited to 'make_table.py')
-rw-r--r--make_table.py13
1 files changed, 10 insertions, 3 deletions
diff --git a/make_table.py b/make_table.py
index 9af49dd..444211d 100644
--- a/make_table.py
+++ b/make_table.py
@@ -23,9 +23,16 @@ result = []
for row in iterator:
if "-" in row[3].text:
continue
+ # For some reason, some skills have multiple IDs. It is not quite clear
+ # what they are for, it sometimes seems to be the traited version, and
+ # sometimes the underwater version. Then again, some of the IDs are also
+ # invalid API IDs, which makes the whole thing a bit weird. Since we don't
+ # care about underwater combat at the moment (and so does nobody else in
+ # GW2) nor about the traited version of skills, we'll just stick with the
+ # first ID. For rendering it shouldn't matter anyway, as all of them
+ # usually share the same icon.
ids = row[3].text.strip().split(";")
palette_id = int(row[4].text)
- for skill_id in ids:
- skill_id = int(skill_id)
- result.append((skill_id, palette_id))
+ skill_id = int(ids[0])
+ result.append((skill_id, palette_id))
print(json.dumps(result))