diff --git a/HistOffline.lua b/HistOffline.lua
index c29b0db..8f3cffe 100644
--- a/HistOffline.lua
+++ b/HistOffline.lua
@@ -109,16 +109,52 @@ for id,_ in pairs (SQ_dat) do -- Load all Quest Data by Achievement ID
if SQ_Info[key] == nil then
SQ_Info[key] = {}
- SQ_Info[key].quest = {}
SQ_Info[key].quests = {}
SQ_Info[key].L = L -- Save separating it out from key later
SQ_Info[key].C = C
end
-
table.insert(SQ_Info[key].quests,id)
end
-
+-- Create SkillQuest Achievements Detail Boxes=======================
+-- These are the same for all chars, we just just hightlight the contents appropriately
+
+SQ_Detail_box= {}
+-- accounts[acc].name[char].SQ_Frame = iup.frame{title = "Quest Details"} -- Panel for details
+
+local info, name, link
+for key, info in pairs(SQ_Info) do -- for each zone
+ --print (key, dump(info))
+ SQ_Detail_box[key]= iup.matrix {numcol=2, numcol_visible=2, numlin=0}
+
+ local Line = 1
+ SQ_Detail_box[key]:setcell(0,0, L.Ach_ID)
+ SQ_Detail_box[key]:setcell(0,1, L.Name)
+ SQ_Detail_box[key]:setcell(0,2, L.Link)
+ iup.SetAttribute(SQ_Detail_box[key], "READONLY", "YES")
+ iup.SetAttribute(SQ_Detail_box[key], "ALIGNMENT0", "ACENTER")
+ iup.SetAttribute(SQ_Detail_box[key], "ALIGNMENT1", "ALEFT")
+ iup.SetAttribute(SQ_Detail_box[key], "ALIGNMENT2", "ALEFT")
+ iup.SetAttribute(SQ_Detail_box[key],"WIDTH0", "30")
+ iup.SetAttribute(SQ_Detail_box[key],"WIDTH1", "150")
+ iup.SetAttribute(SQ_Detail_box[key],"WIDTH2", "250")
+ for _, id in ipairs (info.quests) do -- get the quests of the zone
+ -- print (dump(id))
+ SQ_Detail_box[key].numlin = Line
+ SQ_Detail_box[key]:setcell(Line,0, tostring(id))
+
+ if Ach_Detail[id] == nil then
+ name = "UNKN"
+ else
+ name = Ach_Detail[id].name
+ end
+ link = SQ_dat[id].link1
+ SQ_Detail_box[key]:setcell(Line,1, name)
+ SQ_Detail_box[key]:setcell(Line,2, link)
+ --print(name, link)
+ Line= Line+1
+ end
+end
accounts = {}
@@ -601,10 +637,11 @@ btn_archive = iup.button{title="Archive", FGCOLOR = "#FF0000"}
-- Need to keep track of multiple achievements for SQ in Zones. Index them by zone LineColumn.
thisSQ_Info = accounts[acc].name[char].SQ_Info
SQ_Faction={}
- local count = 0
- -- Set up box with default data
+ local ccount, count
+ -- Set up box with default data, and adjust
for C=1, 4 do
+ ccount = 0 -- per column
for L = 1, 5 do
key = tostring(L) .. tostring(C) -- make name key
dname = Locations[key] -- Zone Locations
@@ -612,92 +649,32 @@ btn_archive = iup.button{title="Archive", FGCOLOR = "#FF0000"}
break -- only 1 in Coldharbour
end
- -- SQ_count[key] = {count= 0}
- -- SQ_Faction[C] =0
-
+ count = 0
for _, id in ipairs (SQ_Info[key].quests) do -- get the quests of the zone
- -- print (dump(id))
if thischar.ach[id] ~= nil then -- Have we got it?
count =count +1
end
end
+ ccount = ccount + count -- Track the faction (Column)
accounts[acc].name[char].SQ_box:setcell(L,C,dname .. " (" .. tostring(count) .. ")")
+ local colour_cell = "FGCOLOR" .. L .. ":" .. C
if count == #SQ_Info[key].quests then -- Got them all??
- local colour_cell = "FGCOLOR" .. L .. ":" .. C
- iup.SetAttribute(accounts[acc].name[char].SQ_box, colour_cell , Colour_Complete)
- end
+ iup.SetAttribute(accounts[acc].name[char].SQ_box, colour_cell , Colour_Complete) -- Yup
+ end
end -- L
- end --
---[[
- -- Customise it with our achievements
- for id,_ in pairs (SQ_dat) do -- For Achievements we have..
- if thischar.ach[id] ~= nil then
- local L = SQ_dat[id].L
- local C = SQ_dat[id].C
- --Set colour of LC
- local colour_cell = "FGCOLOR" .. L .. ":" .. C
- key = tostring(L) .. tostring(C) -- make name key
- dname = Locations[key] -- Zone Locations
- if dname == nil then
- dname = "SQ key " .. key .." not found"
- end
- -- Increment count and display
- SQ_count[key].count = SQ_count[key].count+1
- accounts[acc].name[char].SQ_box:setcell(L,C,dname .. " (" .. SQ_count[key].count ..")")
- --Check if done
- if SQ_count[key].count >= 2 then
- iup.SetAttribute(accounts[acc].name[char].SQ_box, colour_cell , Colour_Complete)
- end
- --Add to Area Completion
- SQ_Area[C] = SQ_Area[C] +1
+ --Set Column Heading Colours
+ if ccount >= 15 then
+ iup.SetAttribute(accounts[acc].name[char].SQ_box, "BGCOLOR0:" .. tostring(C), Colour_Heading_Complete)
+ end
+ end --
- end
- end
- --]]
--- Create SkillQuest Achievements Detail Boxes=======================
- accounts[acc].name[char].SQ_Detail_box= {}
- accounts[acc].name[char].SQ_Frame = iup.frame{title = "Quest Details"} -- Panel for details
---[[
- local info, name, link
- for key, info in pairs(SQ_Info) do -- for each zone
- --print (key, dump(info))
- accounts[acc].name[char].SQ_Detail_box[key]= iup.matrix {numcol=2, numcol_visible=2, numlin=0}
- local thisbox = accounts[acc].name[char].SQ_Detail_box[key]
- Line = 1
- thisbox:setcell(0,0, "Ach_ID")
- thisbox:setcell(0,1, "Name")
- thisbox:setcell(0,2, "Link")
- iup.SetAttribute(thisbox, "READONLY", "YES")
- iup.SetAttribute(thisbox, "ALIGNMENT0", "ACENTER")
- iup.SetAttribute(thisbox, "ALIGNMENT1", "ALEFT")
- iup.SetAttribute(thisbox, "ALIGNMENT2", "ALEFT")
- iup.SetAttribute(thisbox,"WIDTH0", "30")
- iup.SetAttribute(thisbox,"WIDTH1", "150")
- iup.SetAttribute(thisbox,"WIDTH2", "250")
- for _, id in ipairs (info.quests) do -- get the quests of the zone
- -- print (dump(id))
- thisbox.numlin = Line
- thisbox:setcell(Line,0, tostring(id))
-
- if Ach_Detail[id] == nil then
- name = "UNKN"
- else
- name = Ach_Detail[id].name
- end
- link = SQ_dat[id].link1
- thisbox:setcell(Line,1, name)
- thisbox:setcell(Line,2, link)
- --print(name, link)
- Line= Line+1
- end
- end
- iup.Append(accounts[acc].name[char].SQ_Frame, accounts[acc].name[char].SQ_Detail_box["11"])
+ -- iup.Append(accounts[acc].name[char].SQ_Frame, SQ_Detail_box["11"])
--]]
-- ====================================
-- == Prepare for the user display tabs
diff --git a/data/de.lua b/data/de.lua
index 25e0a51..f674871 100644
--- a/data/de.lua
+++ b/data/de.lua
@@ -54,6 +54,9 @@ Area_names = {
Zone = "Zone",
SkillQuests = "SkillQuests",
SkillLab = "Quests mit Skillpunkt-Belohnung",
+ Ach_ID = "Ach ID",
+ Name = "Name",
+ Link = "Link",
}
pub_names = {
diff --git a/data/en.lua b/data/en.lua
index 6ab5fa4..6519de2 100644
--- a/data/en.lua
+++ b/data/en.lua
@@ -52,6 +52,9 @@ Area_names = {
Zone = "Zone",
SkillQuests = "SkillQuests",
SkillLab = "Quests Awarding a Skill Point",
+ Ach_ID = "Ach ID",
+ Name = "Name",
+ Link = "Link",
}
pub_names = {
diff --git a/data/fr.lua b/data/fr.lua
index 7cc6c27..cb01764 100644
--- a/data/fr.lua
+++ b/data/fr.lua
@@ -51,6 +51,9 @@ Area_names = {
Zone = "Zone",
SkillQuests = "SkillQuests",
SkillLab = "Quests Awarding a Skill Point",
+ Ach_ID = "Ach ID",
+ Name = "Name",
+ Link = "Link",
}
pub_names = {