| Script Boxes: The Script Box allows you to record any series of interactions with the simulator, including buttons pressed; keyboard commands; placing, moving, and altering objects; using tools; and running simulations. To use the Script Box: Clear the simulation window or load an prefabricated setup. Use the Load command from the Standard Menu (Document submenu). If you are starting with a prefabricated setup (see Save HTML), skip this step. Open the Script Box from the Standard Menu (and the simulator submenu on PCs). Click on the Record button. The Play and Clear buttons are now disabled, and the Record button now reads Stop. Return to the simulator. Execute any sequence of actions you wish. When you have finished, click on the Stop button in the Script Box window. Clear the simulation window or reload your prefabricated setup. Use the Load function. DO NOT REFRESH unless you save the script first (see below). Click on the Play button and watch the script execute. If you make an error, click on Clear to delete the script. Then click on Record and re-execute your sequence of actions. You can also edit the script manually as if you were using a text editor. However, this is not recommended except with regard to the delay command. Delay Command: If you want to insert a pause between two commands (for example, between Run and Stop), you should type a delay command directly into the script. The delay command has a simple syntax: delay 1000 where the number indicates the delay in milliseconds. Thus, delay 1000 delays execution of the next command for one second; delay 6000 delays for six seconds; and delay 50 delays for 1/20 of a second. Example: Say your script features a Run command followed by a Stop. The script box will include these two commands: pressTool Run pressTool Stop Since simulations that last a fraction of a second are not all that interesting, you decided to insert a delay command. If you want the simulation to run for 30 seconds, the script box should read: pressTool Run delay 30000 pressTool Stop File Menu: Open the File menu by clicking on the word File above the script window. This menu has two options: Load: Load a saved or prefabricated script. If you load a script, skip steps 3-5 above. Save: Save the script under a name you choose.