LitDev Extension API

GW LD3DView LDArray LDBits LDBlueTooth
LDCall LDChart LDClient LDClipboard LDColours
LDCommPort LDController LDControls LDCursors LDDataBase
LDDateTime LDDebug LDDialogs LDDictionary LDEffect
LDEmail LDEncryption LDEvents LDFastArray LDFastShapes
LDFigures LDFile LDFinances LDFocus LDftp
LDGeography LDGraph LDGraphicsWindow LDHashTable LDHID
LDIcon LDImage LDInline LDIOWarrior LDList
LDLogic LDMath LDMathX LDMatrix LDMusic
LDNetwork LDPhysics LDProcess LDQueue LDRegex
LDResources LDScrollBars LDSearch LDServer LDSettings
LDShapes LDShell LDSort LDSound LDSpeech
LDStatistics LDStopwatch LDText LDTextWindow LDTimer
LDTranslate LDUnits LDUtilities LDVector LDWaveForm
LDWebCam LDWindows LDxml LDZip TW

LDStopwatch
Accurate system stopwatches.

Add DelayUpTo ElapsedMilliseconds
ElapsedTicks Frequency Reset
Restart Start Stop

Add()
Create a new stopwatch.
returns The stopwatch name.

DelayUpTo(delay)
Delay up to a maximum interval since the last time this is called.
Useful in a game loop to maintain an even play speed.

delay The maximum delay in ms.

ElapsedMilliseconds(stopwatch)
Gets the total elapsed time measured in milliseconds.
stopwatch The stopwatch name.
returns Elapsed milliseconds.

ElapsedTicks(stopwatch)
Gets the total elapsed time measured in timer ticks for very short intervals.
stopwatch The stopwatch name.
returns Elapsed ticks.

Frequency
Get the frequency of the stopwatch timer in ticks per second.
This represents the finest resolution of time your hardware can measure with ElapsedTicks.


Reset(stopwatch)
Stops the current stopwatch and resets the elapsed time to 0.
stopwatch The stopwatch name.

Restart(stopwatch)
Stops the current stopwatch, resets the elapsed time to 0 and restarts the stopwatch.
stopwatch The stopwatch name.

Start(stopwatch)
Starts or resumes the current stopwatch.
stopwatch The stopwatch name.

Stop(stopwatch)
Stops the current stopwatch.
stopwatch The stopwatch name.