Irrlua = COOL!

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
shaneedward
Posts: 11
Joined: Tue Apr 04, 2006 7:01 am

Irrlua = COOL!

Post by shaneedward »

I've been messing around with this stuff so I can start on a simple demo for my game and Irrlua looks really cool! No libraries, no includes! No compiling! I can just use Notepad++ and the command line. It looks pretty good to me. What's the down side of using Irrlua? Am I missing out on anything? Will there be performance issues?
Klasker
Posts: 230
Joined: Thu May 20, 2004 8:53 am
Contact:

Post by Klasker »

IrrLua will definitely be slower than a C++ application, but for many simple games (Tetris clones, Pacman 3D, Breakout, etc) and even small RPG/FPS games the difference should not be noticable.
I haven't tried IrrLua myself, but I don't think you can write custom scene nodes using it, so you will be limited to what Irrlicht can do by itself.

Yes, you are definitely missing out on something, but maybe not something you need after all. Depends on your level of ambition ;)
zenaku
Posts: 212
Joined: Tue Jun 07, 2005 11:23 pm

Post by zenaku »

Actually, you can write custom scene nodes with IrrLua. A sample CAnimSprite.lua is included in the download and can also be viewed here http://irrlua.sourceforge.net/CAnimSprite.lua

As far as performance issues go, it really depends on what you try and do with it. On my system (athlon64 + 6800GT), I see ~430 fps running CDemo.lua with vsync turned off. Running Irrlicht's Demo.exe gives me ~450 fps. That's a pretty small difference, IMO.

On the otherhand, implementing custom scene nodes in lua is not recommended when performance is a concern. Callbacks, like the shader callbacks, can also be expensive. 10.Shaders.lua gives ~280 fps while Shaders.exe gives ~500 fps.

For the most part, it works well enough.
-------------------------------------
IrrLua - a Lua binding for Irrlicht
http://irrlua.sourceforge.net/
shaneedward
Posts: 11
Joined: Tue Apr 04, 2006 7:01 am

Post by shaneedward »

Hm, CAnimSprite.lua didn't do anything when I ran it. No window, no nothing.
zenaku
Posts: 212
Joined: Tue Jun 07, 2005 11:23 pm

Post by zenaku »

CAnimSprite.lua is just a class. It doesn't have any code to display the custom scene node. The actual code that displays the class is called CAnimSpriteTest.lua.

http://irrlua.sourceforge.net/CAnimSpriteTest.lua
-------------------------------------
IrrLua - a Lua binding for Irrlicht
http://irrlua.sourceforge.net/
Post Reply