SA-MP Forums Archive
Need the dialog show only once in PickUp - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Need the dialog show only once in PickUp (/showthread.php?tid=335052)



Need the dialog show only once in PickUp - tal_peretz - 16.04.2012

I want to show to player dialog when he picks up pickup .. the problem that I want to check if player is already exists in the pickup and not show him again the dialog, any ideas ?

Thanks alot


Re: Need the dialog show only once in PickUp - ViniBorn - 16.04.2012

It help?

http://forum.sa-mp.com/showthread.ph...=dialog+buffer


Re: Need the dialog show only once in PickUp - tal_peretz - 17.04.2012

Quote:
Originally Posted by Viniborn
Посмотреть сообщение
Great!! Thanks alot


Re: Need the dialog show only once in PickUp - MP2 - 17.04.2012

No that won't help, it will just que it 10 times.

He means, when you stand in a pickup, it spams OnPlayerPickUpPickup every second, what you need to do is set a variable to 1 when they enter the pickup, and when they close the dialog set a 5 second timer, on that timer set it to 0 (so they move out of the way). Remember to set it to 0 on connect.


Re: Need the dialog show only once in PickUp - tal_peretz - 17.04.2012

Quote:
Originally Posted by MP2
Посмотреть сообщение
No that won't help, it will just que it 10 times.

He means, when you stand in a pickup, it spams OnPlayerPickUpPickup every second, what you need to do is set a variable to 1 when they enter the pickup, and when they close the dialog set a 5 second timer, on that timer set it to 0 (so they move out of the way). Remember to set it to 0 on connect.
and how can I check when he closed the dialog ? that is my problem.. check the response is not enough.