Crystal AI  1.0.0
Crystal.CommandStream Class Reference

The CommandStream processes a given fraction of the AI events on every loop. More...

Public Member Functions

IDeferredCommandHandle Add (DeferredCommand cmd)
 Adds the specified command. More...
 
void Process ()
 Processes as many items as possible withing the given Time limits. More...
 
 CommandStream (int initialQueueSize)
 Initializes a new instance of the T:Crystal.CommandStream class. More...
 

Properties

double MaxProcessingTime [get, set]
 The maximum Time in milliseconds the Process() is allowed to take. More...
 
float ExtraTimeNeeded [get]
 Gets the accumulated number of seconds the updates were overdue this frame, i.e. sum of all updates. More...
 
double TotalMilliseconds [get]
 Total milliseconds used on the last Process(). More...
 
int ProcessedCount [get]
 The number of items in the queue that were processed during the previous cycle. More...
 
int CommandsCount [get]
 The number of scheduled commands in the queue. More...
 

Detailed Description

The CommandStream processes a given fraction of the AI events on every loop.

Constructor & Destructor Documentation

Crystal.CommandStream.CommandStream ( int  initialQueueSize)
inline

Initializes a new instance of the T:Crystal.CommandStream class.

Parameters
initialQueueSizeInitial queue size.

Member Function Documentation

IDeferredCommandHandle Crystal.CommandStream.Add ( DeferredCommand  cmd)
inline

Adds the specified command.

Parameters
cmdThe command.
Returns
void Crystal.CommandStream.Process ( )
inline

Processes as many items as possible withing the given Time limits.

Property Documentation

int Crystal.CommandStream.CommandsCount
get

The number of scheduled commands in the queue.

float Crystal.CommandStream.ExtraTimeNeeded
get

Gets the accumulated number of seconds the updates were overdue this frame, i.e. sum of all updates.

double Crystal.CommandStream.MaxProcessingTime
getset

The maximum Time in milliseconds the Process() is allowed to take.

The max process Time.

int Crystal.CommandStream.ProcessedCount
get

The number of items in the queue that were processed during the previous cycle.

double Crystal.CommandStream.TotalMilliseconds
get

Total milliseconds used on the last Process().


The documentation for this class was generated from the following file: