Questie

Questie

116M Downloads

Working with collapsed quest log.

rasberryrabbit opened this issue ยท 9 comments

commented

I make another code that don't expand quest log.

GetNumQuestLogEntries() second return value has real quest counts whether or not it is collapsed.
And quest information can retrieve by addon API.

I make simple code for retrieve quest list.

function q_test()
local numEntries, numQuests = GetNumQuestLogEntries()
DEFAULT_CHAT_FRAME:AddMessage(numEntries .. " entries containing " .. numQuests .. " quests in your quest log.");
local i=1;
local qc=0;
while qc<numQuests do
local q, _, _, isHeader, isCollapsed, _ = GetQuestLogTitle(i);
DEFAULT_CHAT_FRAME:AddMessage(i.." "..q)
if not isHeader then
qc=qc+1
else
DEFAULT_CHAT_FRAME:AddMessage("----")
end
i=i+1
end
end

I also make patch for current dev version.

patch_3.5_diff.txt

It work good at my testing.

commented

I'll have to peer review this change to make sure it doesn't break Shagu or EQL3 QuestLog mods. I'm sure it works fine with the default WoW Quest Log. Your other suggestion I incorporated in my code checkin already. It simply expands the collapsed section if you hover over a quest item in your bag and leaves the section open.

Your saying this change will open the section, paint the tooltip and then close the section again?

commented

No. It doesn't touch section. I guess it solves collapsed section problem without expanding section and I refine patch.
Sometimes Questie doesn't update its own hash list, I make changes with it.

patch_3.5_diff_rev2.txt

commented

These code changes look good! I'll get them checked in.

commented

I found "GetQuestLogQuestText" doesn't work with collapsed quest.

I replace "QGet_QuestLogQuestText" with,

function QGet_QuestLogQuestText()
local rtext=""
for i=1, GetNumQuestLeaderBoards() do
local qtext, qtype, qfin = GetQuestLogLeaderBoard(i)
local cp=strfind(qtext,":")
if cp==nil then
cp=strlen(qtext)
else
cp=cp-1
end
rtext=rtext.." "..strsub(qtext,1,cp)
end
return qtype, rtext
end

Now work correcly with collapsed quest logs but it's not perfect.

patch_3.5_diff_rev3.txt

commented

Can you attach copies of all the files you changed to this thread? You'll have to rename each file from a *.LUA to *.TXT before this forum will allow you to attach the file. Going through the patch_3.5_diff_rev3.txt file and manually typing all the changes is tedious.

commented

Sorry for rev3 patch. I have faults on wow DB.
"GetQuestLogQuestText" works correctly. It's my fault.
Clear wow DB file and works ok.

Questie.lua.txt
QuestieQuest.lua.txt
QuestieTracker.lua.txt
patch_3.5_diff_rev4.txt

commented

The changes in these three files don't match what is contained in: patch_3.5_diff_rev3.txt

commented

According to "patch_3.5_diff_rev3.txt" I see the new function: QGet_QuestLogQuestText() but I fail to see the reason it was added to both "QuestieNotes.lua" and "QuestieQuest.lua". This function also conflicts with "QGet_QuestLogQuestText" since it's already mapped to the Blizzard API call "GetQuestLogQuestText". Your changes make no sense.

Your previous changes did make sense and it improved quest updates. Please re-sync your version of Questie with the code changes that have already been made to the master branch instead of continuing to make changes to your local branch. Run through your list of test cases and open a fresh bug if one is found.

commented

Thank you!