Hello folks.
I'm not clever enought and I like to spam the forum with questions...
So here I go:
I accept a quest in Dalanis and it is possible to result in 3 different quests.
So actually the event npc offers one quest out of a pool of three. All of the same name but different things to do.
I accept the quest anyways but want do decide by id it's Id which path to take.
Or is there something like AcceptQuestById() so that i just try all three and see qhich is possible to accept?
thanks in advance
Getting QuestId from List
Re: Getting QuestId from List
Well, AcceptQuestByName(nameorid) will return true if a match is found. So you could do
Code: Select all
if AcceptQuestByName(id1) then
-- do quest 1 stuff
elseif AcceptQuestByName(id2) then
-- do quest 2 stuff
elseif AcceptQuestByName(id3) then
-- do quest 3 stuff
end
- Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
- I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
- How to: copy and paste in micromacro
________________________
Quote:- “They say hard work never hurt anybody, but I figure, why take the chance.”
- Ronald Reagan
Re: Getting QuestId from List
Well... not working for me :/
I definately gor the quest with finding cloth puppet, but the bot insists of saing he got another quest but not that one.
So now I'd like to recheck the Id of the quest with the given name.
Any idea?
Code: Select all
if AcceptQuestByName(423751) then
-- do chain
__WPL:setWaypointIndex(__WPL:findWaypointTag("silverchain"));
elseif AcceptQuestByName(423662) then
-- do wooden box
__WPL:setWaypointIndex(__WPL:findWaypointTag("woodenbox"));
elseif AcceptQuestByName(413859) then
-- do puppet
player:sleep()
__WPL:setWaypointIndex(__WPL:findWaypointTag("clothpuppet"));
end
So now I'd like to recheck the Id of the quest with the given name.
Any idea?
Re: Getting QuestId from List
I think maybe some offsets have changed. I'll look into it later.
- Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
- I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
- How to: copy and paste in micromacro
________________________
Quote:- “They say hard work never hurt anybody, but I figure, why take the chance.”
- Ronald Reagan
Re: Getting QuestId from List
I see, they all have the same name. Similar to the Invaders bags quest.
I think the AcceptQuestByName compares the names so it probably always does the first one.
I think what you have to do is accept the quest first then see what id it has. I think getQuestStatus compares ids. Try Note: the last id was wrong.
I think the AcceptQuestByName compares the names so it probably always does the first one.
I think what you have to do is accept the quest first then see what id it has. I think getQuestStatus compares ids. Try
Code: Select all
AcceptQuestByName("Auermo's Confession") -- Or use any of the 3 ids
if getQuestStatus(423751) ~= "not accepted" then
-- do chain
__WPL:setWaypointIndex(__WPL:findWaypointTag("silverchain"));
elseif getQuestStatus(423662) ~= "not accepted" then
-- do wooden box
__WPL:setWaypointIndex(__WPL:findWaypointTag("woodenbox"));
elseif getQuestStatus(423859) ~= "not accepted" then
-- do puppet
player:sleep()
__WPL:setWaypointIndex(__WPL:findWaypointTag("clothpuppet"));
end
- Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
- I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
- How to: copy and paste in micromacro
________________________
Quote:- “They say hard work never hurt anybody, but I figure, why take the chance.”
- Ronald Reagan
Re: Getting QuestId from List
Thanks a lot.
Looks like it's working
Looks like it's working
Who is online
Users browsing this forum: Bing [Bot] and 1 guest