osrsbox / osrsbox-db

A complete and up-to-date database of Old School Runescape (OSRS) items, monsters and prayers
https://www.osrsbox.com/projects/osrsbox-db/
GNU General Public License v3.0
227 stars 83 forks source link

Items with colour variants parses incorrect data #124

Closed jakebellotti closed 5 years ago

jakebellotti commented 5 years ago

When an item has colour variants, the data isn't scraped correctly. For example, the Graceful Hood: https://oldschool.runescape.wiki/w/Graceful_hood

Has multiple different coloured variants. They have different examine descriptions, and release dates.

Normal variant: https://www.osrsbox.com/osrsbox-db/items-json/11850.json Agility arena variant: https://www.osrsbox.com/osrsbox-db/items-json/21061.json

However, as seen in the above files, it only scrapes data for the regular version. This means release date and examine are incorrect. In other items, potentially other values could be incorrect.

osrsbox commented 5 years ago

I think this will be possible by comparing item inventory icons from the cache and determining what version (colorway) the item actually is... I have done this for other items such as brodo shields and castlewars armour. Doesn't seem like too much effort to add/fix.

jakebellotti commented 5 years ago

The wiki should have the item IDs on the info box, just make sure to check the data you scrape corresponds with the current item ID on the scraper end.

osrsbox commented 5 years ago

Just about to close this issue. The next commit will have this issue fixed - and have manually checked the graceful variants which all seem correct. Will also push the new PyPi version 1.1.20 will have this change implemented.