SA-MP Forums Archive
Is this loop called everytime? - 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: Is this loop called everytime? (/showthread.php?tid=367208)



Is this loop called everytime? - ddnbb - 09.08.2012

Okay, so I have right under public OnDialogResponse a new houseid = GetHouse(playerid); That "GetHouse(playerid)" is a loop to get house ID's. So my question: is that loop getting called every single time, that any dialog gets opened?


Re: Is this loop called everytime? - Abhishek. - 09.08.2012

well if you kept it just under it but you would have done your house id thing in a single dialog response not ever dialogs so it will be called when you response to the given dialog,if you get it what i say


Re: Is this loop called everytime? - Roperr - 09.08.2012

Yes, indeed it does get called when ANY dialog is called. You could simply add those lines under the dialog that actually needs them.


Re: Is this loop called everytime? - ddnbb - 09.08.2012

Ok, thanks, just as i thought!