Scripts are files that contain commands. By convention, these scripts have the file extension .q. They are normal text files which you can create using any text editor, such as Notepad, Emacs, etc.

Scripts can contain single-line and multi-line commands.

Scripts can contain comments: everything after a percent sign is ignored by the interpreter (actually, the % sign can be used to terminate every statement or expression, but it only makes sense in scripts). Use comments to document your scripts, for example:

 % Suspend script for one turn.
 % Execution proceeds next turn (or later, when a turn is missed).
 Sub WaitOneTurn ()
   Local t = Turn          % Save turn number
   Do While t = Turn       % Wait until turn number changes
     Stop
   Loop
 EndSub

Script files must contain complete commands. A multi-line command that started in a file must end within the same file.