TGL scripts structure

Here is the structure of text scripts:

[#package packageName]

([#import importName])*

[#metatype metatypeName]

([#script visibility scriptName(scriptParameters)]
(body statement)*
[/#script])*

Related concepts
Script