Scripting WhiteCap

WhiteCap has scripting services that allow you to repeat WhiteCap performances and allow you to synchronize WhiteCap events to a timeline or "timecode". A short example script is already included to demonstrate WhiteCap scripting, and you can start it by pressing CTRL and the '3' key. If you find the folder named "Scripts" and open the file "3 Key" using a text editor, you'll notice how time indexes are on the left and keystrokes and config names are on the right. Once a script is started/called, the commands on the right are executed along the timeline on the left.

There's two ways to start a script. The first way is to name a script "X Key" and press CTRL and the X key (or whatever key you want). The other way to start a script is to call it by name from inside another script.

The format of command lines (ie, the lines that appear to the right of the time indexes) are keystrokes or config names separated by semicolons. In other words, whatever is between semicolons is one of two things: a single character (as if you typed it in from the keyboard) or the filename of a config or script. Whenever WhiteCap encounters a config or script name in a command line, then it will run it accordingly. A trailing asterisk after a config will make G-Force transition/morph from the present config to what you've specified (as opposed to instantly switching to what you've specified).

The following are the contents of some of the included scripts found in the "Scripts" folder. They're designed to give you a basic understanding how scripting works.

(The text file "1 Key": Pressing '1' switches to the given config, NeoWorld. 5 seconds later we put WhiteCap back into slideshow mode.)
0:00 Neo World
0:05 G

(The text file "2 Key". Pressing '2' shows how adding a '*' to the end of a config name causes WhiteCap to transition/morph to that config vs. a quick one-second transition. Also note how the '\' are used to turn console text on and off.)
0:00 \;AKIRA Phase
0:10 Total Recall*
0:28 AKIRA Phase*
0:40 \

Sometimes, you'll want WhiteCap to automatically to start a script when a certain audio track starts. Whenever a new audio file is played in your audio player, WhiteCap will look for a script or config with a matching name to start. If the audio file is an mp3 file and internally defines the track name (ex, ID tag data), then G-Force will use that instead. For example, suppose you have a script that's made to go with a file named "Andy sings opera.wav", and it's written so that 0:00 corresponds to the start of the music file. Rename your script to "Andy sings opera" (remember: extensions are ignored in G-Force), restart G-Force, and play your audio file.