The types of data scripting can manipulate can be virtually anything – from a sentence, to numbers, to squads and entities. Dawn of War will use a variety of data types to perform scripting operations.
Basically, a data type is how information is stored. An integer (1, 250, -5), is different to a string («Hello», 5), for instance.
In the LUA language SCAR is based on, however, you do not declare any data types in your scripts. These data types, while in exsistance, are transparent and basically change as you change them:
function Test() -- Variable is stored as an integer local variable = 10 -- Variable is changed to a string, 10 no longer exsists. variable = "hello" -- Variable is set to a null/invalid value variable = nil end
They are used in the Functions reference to declare what data needs to be put in, or is retrived from the different functions – so you know if a function returns an Integer amount of something (such as amount of units), or a Real value of something (like a percentage of health).
Basic data types (See also
LUA Types Documentation for good information):
These are sub-types of the above, specifically used in SCAR-related data types: