LUA Programming Language

Ever wondered how your PC games and photoshops work? You can save some time! It’s all thanks to Lua. Lua is the leading programming language in building games and photo shops. Lua is a multi paradigm programming language which is considered to be light weight. There are many advantages of Lua in terms of the programmer. It is considered as a scripting language which has extensible semantics as its primary goal. The article will give you a gist of what Lua is all about.

Overview

In 1993, Roberto lerusalimschy was responsible for the development of Lua. He along with his colleagues Waldemar Celes and Luiz Henrique created this amazing language. Computer Graphics Technology Group (Techgraf) at the University of Pontifical Catholic at Rio de Janeiro, in Brazil, was where Lua took birth. In Portuguese lua means ‘moon’.

It is considered that the historical mother and father of Lua are SOL (simple object language) and DEL (data-entry language). SOL was used to do the data- description, it is a configuration language. They both were developed independently so that there is flexibility to the programming language. But soon they realized that there were no flow control structures in SOL and DEL. This led to making Lua a complete programming language.

At this juncture, Techgraf couldn’t depend on the existing programming languages. Python, LISP, Scheme were all denied because of various syntax and semantic problems. Then they gathered their resources in the company and started working on the platforms which they already have. They realized that they have many diversified platform by which they could build their own scripting language. This also came good for them as the other products of Techgraf also needed scripting language.

Lua 1.0 was launched in 1993 for the first time. The syntax which is used in this version was adapted from Modula. Apart from this they have also borrowed syntax from CLU, C++, SNOBALL and AWK.

Till Lua5.0, the license was of the software was being supported by BSD license. After this version MIT took up the license of Lua programming language.

LUA Features

Lua programming language is a multi paradigm programming language. The specialty of this language is it works on simple procedural syntax with high level description constructs which are based on extensive semantics. Some of the salient features of Lua are described below.

It is dynamically typed and runs on interpreting bytecode to a register based virtual machine.
It is light weighted and is very flexible in terms of programming.
It has got an excellent memory management system which will help the programs to execute faster.
Lua is also robust in nature and has a faster performance when compared to its counter parts.
Lua has advanced features which include first-class functions, proper tail calls, coercion (which means automatic communication between string and number values), coroutines (multitasking) and dynamic module modeling.
It is small in size too. Lua has always been trying to strike a balance between its size and power.
Lua is open source software. It is distributed with a very liberal license policy by MIT license.

LUA Applications

Gaming field has been the most benefited of all with the creation of Lua. Most of the gaming companies use Lua programming language to design their games. Game programmers used Lua as scripting language and also to add the 3D affect to their games. Some other common applications which are developed by Lua are Adobe Photoshop Lightroom (which is used to modify and edit digital photographs), Celestia (it’s an educational program for astronomy), Awesome (it is a window manager) and many more such utility tools use Lua programming language.