EvilZone

Programming and Scripting => Scripting Languages => : Flikka July 28, 2011, 05:32:58 AM

: Lua
: Flikka July 28, 2011, 05:32:58 AM
Lua is a powerful, fast, lightweight, embeddable scripting language.Lua combines simple procedural syntax with powerful data description constructs based on associative arrays and extensible semantics. Lua is dynamically typed, runs by interpreting bytecode for a register-based virtual machine, and has automatic memory management with incremental garbage collection, making it ideal for configuration, scripting, and rapid prototyping.

Lua has been used in many industrial applications, with an emphasis on embedded systems (e.g., the Ginga (http://www.ginga.org.br/) middleware for digital TV in Brazil) and games (e.g., World of Warcraft (http://www.wowwiki.com/Lua)). Lua is currently. Lua has a solid reference manual (http://www.lua.org/manual/5.1/) and there are several books about it (http://www.lua.org/docs.html#books). Several versions (http://www.lua.org/versions.html) of Lua have been released and used in real applications since its creation in 1993. Lua featured in HOPL III, the Third (http://research.ihost.com/hopl/HOPL-III.html)ACM SIGPLAN History of Programming Languages Conference (http://research.ihost.com/hopl/HOPL-III.html), in June 2007.


Lua has a deserved reputation for performance. To claim to be "as fast as Lua" is an aspiration of other scripting languages. Several benchmarks show Lua as the fastest language in the realm of interpreted scripting languages. Lua is fast not only in fine-tuned benchmark programs, but in real life too. A substantial fraction of large applications have been written in Lua.


Lua is distributed (http://www.lua.org/download.html) in a small package and builds out-of-the-box in all platforms that have an ANSI/ISO C compiler. Lua runs on all flavors of Unix and Windows, and also on mobile devices (such as handheld computers and cell phones that use BREW, Symbian, Pocket PC, etc.) and embedded microprocessors (such as ARM and Rabbit) for applications like Lego MindStorms.
For specific reasons why Lua is a good choice also for constrained devices, read this summary (http://lua-users.org/lists/lua-l/2007-11/msg00248.html) by Mike Pall.


Lua is a fast language engine with small footprint that you can embed easily into your application. Lua has a simple and well documented API that allows strong integration with code written in other languages. It is easy to extend Lua with libraries written in other languages. It is also easy to extend programs written in other languages with Lua. Lua has been used to extend programs written not only in C and C++, but also in Java, C#, Smalltalk, Fortran, Ada, Erlang, and even in other scripting languages, such as Perl and Ruby.


A fundamental concept in the design of Lua is to provide meta-mechanisms for implementing features, instead of providing a host of features directly in the language. For example, although Lua is not a pure object-oriented language, it does provide meta-mechanisms for implementing classes and inheritance. Lua's meta-mechanisms bring an economy of concepts and keep the language small, while allowing the semantics to be extended in unconventional ways.


Adding Lua to an application does not bloat it. The tarball for Lua 5.1.4 (http://www.lua.org/ftp/lua-5.1.4.tar.gz), which contains source code, documentation, and examples, takes 212K compressed and 860K uncompressed. The source contains around 17000 lines of C. Under Linux, the Lua interpreter built with all standard Lua libraries takes 153K and the Lua library takes 203K.


Lua is free open-source software, distributed under a very liberal license (http://www.lua.org/license.html) (the well-known MIT license). It may be used for any purpose, including commercial purposes, at absolutely no cost. Just download (http://www.lua.org/download.html) it and use it.

Lua is designed, implemented, and maintained by a team (http://www.lua.org/authors.html) at PUC-Rio (http://www.puc-rio.br/), the Pontifical Catholic University of Rio de Janeiro in Brazil. Lua was born and raised in Tecgraf (http://www.tecgraf.puc-rio.br/), the Computer Graphics Technology Group of PUC-Rio, and is now housed at Lablua (http://www.lua.inf.puc-rio.br/). Both Tecgraf and Lablua are laboratories of the Department of Computer Science (http://www.inf.puc-rio.br/) of PUC-Rio

Download: http://www.lua.org/download.html (http://www.lua.org/download.html)
Lua For beginners: http://lua.gts-stolberg.de/en/index.php?uml=1 (http://lua.gts-stolberg.de/en/index.php?uml=1)

(http://www.lua.org/images/lua.gif)
: Re: Lua
: Kulverstukas July 28, 2011, 06:30:40 AM
Don't use the big font, please... and next time post the source maybe?
http://www.lua.org/about.html (http://www.lua.org/about.html)
: Re: Lua
: xor July 28, 2011, 01:27:49 PM
My friend wrote a browser for linux using LUA. After 5 days it was in all the major repo's.

http://luakit.org/projects/luakit/ (http://luakit.org/projects/luakit/)
: Re: Lua
: Stackprotector July 29, 2011, 12:18:41 PM
I have wrote several minigames-instances-raids-bosses for world of warcraft private server (projectsilvermoon\funDB) in lua.
It does the job pretty good :)