Go to: Synopsis. Return value. Flags. MEL examples.

Synopsis

currentTime [-update boolean] [time]

currentTime is NOT undoable, queryable, and editable.

When given a time argument (with or without the -edit flag) this command sets the current global time. The model updates and displays at the new time, unless "-update off" is present on the command line.

Return value

time

In query mode, return type is based on queried flag.

Flags

update
Long name (short name) Argument types Properties
-update(-u) boolean create
change the current time, but do not update the world. Default value is true.

Flag can appear in Create mode of command Flag can appear in Edit mode of command
Flag can appear in Query mode of command Flag can be used more than once in a command.

MEL examples

// Query the current time
//
currentTime -query;

// Change the current time to "30" in current time units
//
currentTime -edit 30;
currentTime 30;

// Change the current time to 2 seconds
//
currentTime -edit 2sec;

// Change the current time, but do not cause the model
// to update.
//
currentTime -edit -10 -update no;