2 registered members (Akow, tomaslolo),
1,536
guests, and 12
spiders. |
Key:
Admin,
Global Mod,
Mod
|
|
|
Re: Has anyone integrated LUA with 3dgs?
[Re: clone45]
#181643
02/02/08 18:05
02/02/08 18:05
|
Joined: Jul 2001
Posts: 6,904
HeelX
Senior Expert
|
Senior Expert
Joined: Jul 2001
Posts: 6,904
|
Afaik LUA is natively includable into ANSI-C programs without any fancy STL stuff, so it should be easy to plug it in (into Lite-C).
Last edited by HeelX; 02/02/08 18:05.
|
|
|
Re: Has anyone integrated LUA with 3dgs?
[Re: Excessus]
#181647
02/02/08 18:53
02/02/08 18:53
|
Joined: May 2002
Posts: 7,441
ventilator
Senior Expert
|
Senior Expert
Joined: May 2002
Posts: 7,441
|
yes, lua could be a complete replacement of lite-c if you made wrapper for the engine sdk. i would find it more interesting to embed lua into lite-c though like that tutorial on gamedev.net describes. that could be useful for many things. for example you could use it as a simple yet powerful system for ini files, for string processing, for making parts of your scripts modifiable,... http://www.coniserver.net/ubbthreads/sho...e=0&fpart=2it could be used for scripting robots in an updated arena game. you could make only the wanted functions and variables available in lua. Quote:
What advantages does LUA have over Lite-C?
lua is a dynamic language. it's slower than lite-c but more high level. it supports object orientation, automatic memory management, its string functions are more powerful,...
|
|
|
Re: Has anyone integrated LUA with 3dgs?
[Re: ventilator]
#181648
02/05/08 16:54
02/05/08 16:54
|
Joined: Jan 2006
Posts: 1,829 Neustadt, Germany
TWO
Serious User
|
Serious User
Joined: Jan 2006
Posts: 1,829
Neustadt, Germany
|
Because the Lite-C compiler is only half-conform with the ANSI-C standard, it shouldnt be that easy to integrate lua directly into LC. Additionally, binding functions directly to lua in ugly, boost::luabind should be used in combination with C++.
I used lua in some projects of mine, it's great for configuration and events aso. But writing a whole game with it? This will make you crazy because the language itself it crazy =) And please note, lua does not directly support OO features, these things are just some language hacks.
Python it a far better scripting language for big things like a complete game. Py directly supports OO features, the language itself offers more things and it has a great set of standard library
|
|
|
|