Functions
Functions are special commands that can be run in chat bots, overlay widgets, and Flow templates (such as the Generate Text node). Unlike Variables they allow extra options when using them.
The format for a Function is $(functionName [requiredOption] <optionalOption>)
When a Function does not require any options, it can be written simply as $(functionName).
The order of options does not matter, and when a Function uses a "value" option, Variables can also be used (see $(math) for best examples of this).
Time and duration
- $(formatDuration) formats a number of seconds as a clock, like
01:30. - $(countdown) counts down to a point in time, like
01:23:45.
Animation
- $(sine) glides smoothly between two numbers, for swaying, bobbing and pulsing widgets.