WakeupAt (System function): Difference between revisions
Jump to navigation
Jump to search
mNo edit summary |
mNo edit summary |
||
Line 2: | Line 2: | ||
The <var>[[WakeupAt (System function)|WakeupAt]]</var> function is an enhanced alternative | The <var>[[WakeupAt (System function)|WakeupAt]]</var> function is an enhanced alternative | ||
as the User Language <var>Pause</var> statement, allowing wakeup time resolution of 1 millisecond, | as the <var class="product">User Language</var> <var>Pause</var> statement, allowing wakeup time resolution of 1 millisecond, | ||
and returns the current time in milliseconds. | and returns the current time in milliseconds. | ||
==Syntax== | ==Syntax== |
Revision as of 20:47, 10 October 2012
Wake up at a specific time in milliseconds (System class)
[Introduced in Sirius Mods 7.9]
The WakeupAt function is an enhanced alternative
as the User Language Pause statement, allowing wakeup time resolution of 1 millisecond,
and returns the current time in milliseconds.
Syntax
[%number =] %(System):WakeupAt( timeInMilliseconds)
Syntax terms
%number | The current time, after waking up, in milliseconds. |
---|---|
%(System) | The class name in parentheses denotes a shared method. WakeupAt can also be invoked via a System object variable, which may be Null. |
timeInMilliseconds | The time, in milliseconds, at which to wake up. |
Usage notes
Examples
The following code fragment pauses for 1 second at the start of each iteration of the Repeat loop:
%time = %(system):currentTimeMilliseconds repeat %time = %time + 1000