Key Elements of the Language
SenseTalk in a Nutshell
SenseTalk is a powerful, high level, and easy-to-read language. It is designed to be similar to English, avoiding cryptic symbols and rigid syntax when possible, in order to be both easy to read and to write. This section briefly describes many aspects of the language.
The information presented here is intended to provide a quick overview of most of the key elements of SenseTalk. Experienced scripters and programmers may find this is enough to get them started using SenseTalk. Other users may want to skim over this section to get a quick sense of what’s ahead before moving on to the more detailed explanations in following sections.
You may also find this section to be a convenient place to turn later when all you need is a quick reminder of how things work. For each topic, references are given to the section where more complete information may be found.
Scripts
A SenseTalk script is a series of command statements. This is often stored as a text file on your computer. When the script is run, each statement is executed in turn. Commands usually begin with a verb, and are each written on a separate line.
One of the first things you will notice about SenseTalk as you write scripts is the colorization. The script is color-coded indicating what the various parts of the script are. For instance, a variable will have a different color than a string literal. Bold and italic are also used to differentiate the different components of a script. There are multiple script themes available, and the styling can also be fully customized in the Eggplant Functional Script Preferences Theme Pane.
SenseTalk is not case-sensitive; commands can be written in uppercase, lowercase, or a mixture without changing the meaning.
Example:
Put 7 Into days
multiply Days by 4
PUT DAYS -- Prints "28"
(See Script Structure and Control Flow)
Simple Values
In SenseTalk there are simple values.
Examples:
5 -- number
sixty-four -- number expressed in words
"❤ hello ❤" -- text string (full international Unicode text allowed)
@"Hello\nNew\nWorld" -- text string with escape codes
empty -- constant
0x7F -- hexadecimal number
<3FA64B> -- binary data