Scripting Reference

The Lua Reference Manual

For convenience the 5.0 Lua Reference Manual is available here in addition to its home at Lua.org. Strata Design 3D CX currently uses version 5.0.2 of the open source Lua programming language with some features of the 5.1 release.

Probably the best book on for getting started in Lua programming is Programming in Lua. It covers the basics and then some.

The Luabind home page hosts the open source project that made embedding Lua into Strata Design 3D CX relatively pleasant. This is very low level stuff but potentially useful even for the casual script writer in its discussion of Luabind classes and derivation. Most of the functionality in Strata Design 3D CX is exposed as Luabind classes.

The user created and supported site The Lua Users Wiki is filled with lots of good information. Go directly to the tutorial page for the best parts. Lots of other useful documentation is also available at the Lua home site along with the Lua License.

The Strata Runtime

The Strata additions to the Lua runtime environment adhere to the following naming conventions:

Private data and declarations begin with an underscore, as in "_leave_me_alone!" This private intent should be respected and the value should be left alone.

Inside the s3d module the following conventions are observed:

Classes and functions begin with an upper case letter followed by lower case characters and/or numerals. Names consisting of multiple words use internal capitals at each word break.

Data in the form of module/table and object fields start with a lower case letter and may have any mix of upper and lower case after that. Internal underscores may also be present at word breaks.

Outside the s3d module we follow the prevailing Lua naming convention, which seems to be:

Everything starts with a lower case letter.

Most of our additions to the Lua runtime are kept within the s3d module, however some useful additions are also available in the global table.

The SDK Exports

A low level listing of the Luabind supplied exports is available here without any comments. See the previous section for actual documentation of the available functionality.