cralor / TourGuideClassic

Tekkub's TourGuide updated for World of Warcraft Classic
3 stars 3 forks source link

Local QuestUseItem Database #2

Open Sefriol opened 5 years ago

Sefriol commented 5 years ago

This might be little ambitious idea, but I kinda would like to restore the original UseQuestItem API that was implemented in TBC.

General idea would be that we have local database of the quests we are going to use and dedicated mapping of quest items used in those quests. I think otherwise the operation should be quite normal.

I'm not sure if we can get this information easily anywhere. Maybe we can query wowhead classic ##somehow?

cralor commented 5 years ago

So the fallback is to use the provided item ID via the guide. I think that covers a majority of it.

Are you saying, though, that looking back at TBC APIs, we can re-create some of the automated nature of this Classic-removed functionality?

Cladhaire is currently working on a LightHeaded version for Classic. This is/was TourGuide's database source for mapping NPC locations automatically. It's possible we can use this database for this use as well. I'd have to look into it more.

Sefriol commented 5 years ago

In general, guide might be the simplest solution. My idea would be that we can have multiple guides that can use the database as a reference for those items, so guide would be much simpler to make.

Json example of such database:

123: {
"quest_item_id": 1234,
"other_info_not_available_via_APIs": "W/E"
}
cralor commented 5 years ago

Okay, let's start looking at LightHeaded, as Cladhaire has released a version for Classic.

https://www.wowinterface.com/downloads/info7017-LightHeaded.html#other

Sefriol commented 5 years ago

Basically it has a lot of the same bugs as TourGuide had before we fixed those. I wish the Addon was in Github..

Things noticed so far:

  1. It tries to use some of the old MapAPIs
  2. It tries to generate quest links (TBC thing)

EDIT: I was able to fix most of the issues related to LightHeaded, some problems with TourGuide since it uses functions that do not exist anymore.

cralor commented 5 years ago

Yeah I started to look at it, have you pushed any commits with your attempt? I will check-in some time tonight.

Sefriol commented 5 years ago

I have only fixed Lightheaded, so it does actually work. I think for TourGuide there is only one thing that requires fixing and that's:

https://github.com/cralor/TourGuideClassic/blob/master/Mapping.lua#L112 since LightHeaded:WZIDToCZ(tonumber(zid)) does not exist.