Hold execution for specific time
I'm trying to pause the execution of my program for a few seconds every once in a while. I remember it using the set_task function....but as the night grows later everything seems a bit more cryptic.
How would i pause execution of my program for, say, 0.5 seconds, then continue on with the execution? |
Re: Hold execution for specific time
You can't literally "pause the execution" of your plugin. set_task() is what you would use to execute a function after a certain amount of time. You will have to be more specific to get better answers. Explain exactly what you are trying to do. Also, if you have code, then show your code.
|
Re: Hold execution for specific time
My code:
PHP Code:
[EDIT] it works!! apparently i CAN figure things out.....anyone looking for answers in this thread...please note: PHP Code:
|
Re: Hold execution for specific time
Use it like this:
PHP Code:
|
Re: Hold execution for specific time
so the id parameter in the set_task is the user's id?
say i wanted to send another argument to the ssTask function, would i put that in the parameters[] argument? PHP Code:
and, to get a better understanding, the '.' before 'flags' and 'repeat' do what? |
Re: Hold execution for specific time
Quote:
Quote:
Quote:
PHP Code:
Quote:
|
Re: Hold execution for specific time
Quote:
Quote:
|
Re: Hold execution for specific time
Quote:
|
Re: Hold execution for specific time
didn't work when i tried to compile it. my code.....
PHP Code:
Code:
Welcome to the AMX Mod X 1.8.1-300 Compiler.P.S. i'm aware that code wouldn't run properly, but it would be runtime errors if executed, not compilation errors as it shows here. |
Re: Hold execution for specific time
|
| All times are GMT -4. The time now is 07:42. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.