Class TDeviceTimer

DescriptionHierarchyFieldsMethodsProperties

Unit

Declaration

type TDeviceTimer = class(TReferenceCounted)

Description

Interface for getting and manipulating the device's virtual time.

Hierarchy

Overview

Methods

Public function IsStopped: Boolean; inline;
Public procedure Start; inline;
Public procedure Stop; inline;
Public procedure Tick; inline;

Properties

Public property RealTime: LongWord read GetRealTime;
Public property Speed: Single read GetSpeed write SetSpeed;
Public property Time: LongWord read GetTime write SetTime;

Description

Methods

Public function IsStopped: Boolean; inline;

Returns if the virtual timer is currently stopped.

Public procedure Start; inline;

Starts the virtual timer.
The timer is reference counted, which means everything which calls Stop() will also have to call Start(), otherwise the timer may not start/stop correctly again.

Public procedure Stop; inline;

Stops the virtual timer.
The timer is reference counted, which means everything which calls Stop() will also have to call Start(), otherwise the timer may not start/stop correctly again.

Public procedure Tick; inline;

Advances the virtual time.
Makes the virtual timer update the time value based on the real time. This is called automatically when during TIrrlichtDevice.Run(), but you can call it manually if you don't use this method.

Properties

Public property RealTime: LongWord read GetRealTime;

The current real time in milliseconds of the system.
This value does not start with 0 when the application starts. For example in one implementation the value returned could be the amount of milliseconds which have elapsed since the system was started.

Public property Speed: Single read GetSpeed write SetSpeed;

Returns current speed factor of the timer.
The speed is the factor with which the time is running faster or slower than the real system time.

Public property Time: LongWord read GetTime write SetTime;

The current virtual time in milliseconds.
This value starts with 0 and can be manipulated by setting Time or using Stop(), Start(), etc. This value depends on the set speed of the timer if the timer is stopped, etc. If you need the system time, use the RealTime property.


Generated by PasDoc 0.12.1 on 2012-09-14 17:32:22