Page 1 of 1

flyers for regine test

Posted: Sun Jun 30, 2013 6:18 pm
by gedads
hi here's a script for flyers for regine, can be improved(adding for some npc the message a flyer for me... and your flyer is refused for npc that are not part of the quest ...).
can someone tell me if it works well or if there are errors?

Re: flyers for regine test

Posted: Mon Jul 01, 2013 11:17 pm
by lautan
Thanks i'm going to put this in.

Re: flyers for regine test

Posted: Mon Jul 08, 2013 8:26 pm
by beefypotatoes
This quest has a bug in it. After turning in the quest, you may repeatedly talk to regine and she'll keep thanking you and giving you the reward again. As a result of this, you can't buy spells from her anymore either (just keeps saying thanks and giving you gil, heh). I edited Regine.lua to clear the FFR variable right after receiving the reward gil. Seems to be working, but I'm not sure if this was the right solution or not.

Not as big of an issue, but none of the NPCs actually take any flyers. The variables still get set properly though, so it doesn't impede completeion of the quest at all. You just end it with 15 flyers still in your inventory.

Re: flyers for regine test

Posted: Tue Jul 09, 2013 12:31 pm
by gedads
yes i forgot to clean the var oneventfinish for cs 0x025b

for the npc refusing flyers, i don't get it:
if(player:getQuestStatus(SANDORIA,FLYERS_FOR_REGINE) ==QUEST_ACCEPTED)then
if(trade:hasItemQty(532,1) and trade:getItemCount() == 1 and player:getVar("tradeAnswald") == 0)then
player:messageSpecial(7121);
player:tradeComplete();
player:setVar("FFR",player:getVar("FFR") - 1);
player:setVar("tradeAnswald",1);
player:messageSpecial(7122,player:getVar("FFR"));
elseif(player:getVar("tradeAnswald") ==1)then
player:messageSpecial(7120);
end
end
end;

if quest is active, if you give one item 532 and never give it to him (0) then -> FFR (total flyer count -1 from 17 when you start quest) and give answald var 1 for already given item.
all npcs are on the same model, they should accep it and once you hit 2 then it's the reward cs.
the line player:messageSpecial(7122,player:getVar("FFR")); isn't required, it should just show how many flyer but it's wrong and -2 have to be added since it goes like that: FFR 1 quest taken, 17 flyers received, 2 all flyers given.
i'll check that but maybe launching shop with option since it's a menu like: if(csid == 0x1fe and option 1 or 0)then ... (it should be one of those 2 options returned) will also solve the problem of buying.

Maybe: i forgot to add trade complete for some npcs, it was late when i wrote that.

Re: flyers for regine test

Posted: Tue Jul 09, 2013 1:39 pm
by lautan
I added in trade complete and modified a lot of your patch. Please test on svn and tell me if you find any issues. I'll make sure you can't keep getting the reward.