fixed bug with return values of GetGossipQuests

This commit is contained in:
SabinDeus 2010-02-07 18:07:04 +00:00
parent 8ca09a66ce
commit 93512b01dd

View File

@ -387,9 +387,9 @@ function TI_HandleGossipWindow(gorq)
local ActiveQuests;
local GossipOptions;
if(gorq == "g") then
AvailableQuests = TI_Tabulate(GetGossipAvailableQuests());
ActiveQuests = TI_Tabulate(GetGossipActiveQuests());
GossipOptions = TI_Tabulate(GetGossipOptions());
AvailableQuests = TI_TabulateGossipQuests(GetGossipAvailableQuests());
ActiveQuests = TI_TabulateGossipQuests(GetGossipActiveQuests());
GossipOptions = TI_TabulateGossipOptions(GetGossipOptions());
SAcQ = SelectGossipActiveQuest;
SAvQ = SelectGossipAvailableQuest;
elseif(gorq == "q") then
@ -595,7 +595,7 @@ function TI_StripDescriptors(...)
return x;
end
function TI_Tabulate(...)
function TI_TabulateGossipOptions(...)
local x = {};
local arg = {...};
for i=1, #arg, 2 do
@ -607,6 +607,18 @@ function TI_Tabulate(...)
return x;
end
function TI_TabulateGossipQuests(...)
local x = {};
local arg = {...};
for i=1, #arg, 3 do
local temp = {};
temp.name = arg[i];
temp.type = arg[i+1];
temp.isLowLevel = arg[i+2]
table.insert(x, temp);
end
return x;
end
--[[this function stolen from WhisperCast by Sarris, whom I love dearly for his contribution to Paladins everywhere.