|
本帖最后由 riser 于 2019-12-19 10:32 PM 编辑
不可否认任务 pfQuest 的灰常强大,但是这里就表推荐 pfQuest 了
我也知道如何添加查询任务,但就是任务里面显示两排的就不能查询,单排显示的没问题,问题困扰多量,请哪个高手帮忙看看施以援手,不胜感谢
实现查询的代码应该是:
for i = 1, 10 do
local button = getglobal("gLimQuestionQHObjectButton"..i);
local qhstring = getglobal("QuestHistoryDetailObjective"..i);
if (not qhstring:IsVisible() and gLimQuestion_QuestData and gLimQuestion_QuestData.os and gLimQuestion_QuestData.os and gLimQuestion_QuestData.os.t) then
qhstring:SetTextColor(0, 0, 0);
qhstring:SetText(gLimQuestion_QuestData.os.t);
qhstring:Show();
QuestHistoryDetailDescriptionTitle:SetPoint("TOPLEFT", "QuestHistoryDetailObjective"..i, "BOTTOMLEFT", 0, -10);
end
button:Show();
if (qhstring:IsVisible() and gLimQuestion_QuestData and gLimQuestion_QuestData.os) then
local text = qhstring:GetText();
text = string.gsub(text,"已杀死","");
text = string.gsub(text,":.*","");
for k,v in gLimQuestion_QuestData.os do
local objtext = v.t;
objtext = string.gsub(objtext,"已杀死","");
objtext = string.gsub(objtext,":.*","");
if (objtext==text and v.npc) then
button:ClearAllPoints();
button:SetPoint("TOPLEFT","QuestHistoryDetailObjective"..i,"TOPLEFT", 0, 0);
button:SetPoint("BOTTOMRIGHT","QuestHistoryDetailObjective"..i,"BOTTOMRIGHT", 0, 0);
button:SetID(k);
button:Show();
break;
end
end
end
end
不知道对不对,但是却不知道怎么修改
|
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有帐号?加入我们
x
|