Aliremawi 9 Posted February 5, 2017 Share Posted February 5, 2017 (edited) Hello, I'm currently coding a quest but I'm facing a problem. I would want to do an action the first time the player click the NPC, and then I want the dialog to dissapear. It's working the first time, but if I click on the NPC several time I can see the dialog again. I added a check but it is not enough... Thanks in advance. The Bug : [/url] The Quest : quest set_begin begin state start begin when 20023.chat."killer_BE" with pc.getqf("fake") == 0 begin if pc.getqf("fake") != 0 or pc.getqf("fake") == 1 then say("Oops, there's a problem out there") pc.setqf("fake", 9) else pc.setqf("fake", 5) say("hello there") end end end end Edited August 26, 2022 by Metin2 Dev Core X - External 2 Internal Link to comment Share on other sites More sharing options...
Aliremawi 9 Posted February 5, 2017 Author Share Posted February 5, 2017 up Link to comment Share on other sites More sharing options...
Premium Syreldar 1875 Posted February 5, 2017 Premium Share Posted February 5, 2017 Hi, this is sufficient to fix the problem: http://pastebin.com/rWhXGdPA After the first time you click it, the condition will not be met anymore, so the dialog will never appear again, until you reset the "fake" qf to 0. I suggest you to clear the files in the object folder before doing it. 1 "Nothing's free in this life. Ignorant people have an obligation to make up for their ignorance by paying those who help them. Either you got the brains or cash, if you lack both you're useless." Syreldar Link to comment Share on other sites More sharing options...
Aliremawi 9 Posted February 5, 2017 Author Share Posted February 5, 2017 29 minutes ago, Syreldar said: Hi, this is sufficient to fix the problem: http://pastebin.com/rWhXGdPA After the first time you click it, the condition will not be met anymore, so the dialog will never appear again, until you reset the "fake" qf to 0. I suggest you to clear the files in the object folder before doing it. thanks man its work but i dont know why your quest isnt different with my quest I expect the problem is the object folder thanks for all Link to comment Share on other sites More sharing options...
Premium Syreldar 1875 Posted February 5, 2017 Premium Share Posted February 5, 2017 You're welcome! "Nothing's free in this life. Ignorant people have an obligation to make up for their ignorance by paying those who help them. Either you got the brains or cash, if you lack both you're useless." Syreldar Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now