Page 1 of 1

Scripting language

Posted: Sat Nov 27, 2004 10:25 pm
by Dreglor
I look around on the forums and the web for some sort of better explantion for this but it seams it not much of a disscussed topic
i did look into the "let build a compiler" document wasn't exectly what i wanted and the code he was using was a bit werid i couldn't convert it as well as i thought...

so, i am doing a 2d/3d engine for a game proablem is i want to put a scripting lang into it and im kinda lost on how to do the such, on top of that i want the lang to be compilable meaning that the text is converted to byte code so it faster for the program to execute (in therory)

any help would be nice :)

Posted: Sat Nov 27, 2004 11:45 pm
by GedB
Dreglor,

Why not use LUA?

FloHimself has already done all the hard work for you: http://www.florian-s.com/PBLua/index.html

Lua has already proven iteself in 3D engines and has been used in commercial games.

Posted: Sun Nov 28, 2004 2:26 am
by Dreglor
grr why didn't i find this earlier...
thx

Posted: Sun Nov 28, 2004 3:01 am
by PolyVector
Not sure if Flo fixed the examples, but if you run into problems having a script call a function in your program, try declaring it as a ProcedureCDLL since Lua uses cdecl

Posted: Thu Dec 09, 2004 3:31 am
by BasicGuy
I remember someone in the Blitz3D forums who created a parser/compiler in Blitz (I think) that could read standard Blitz code like it was a scripting language. It was very cool because you didn't need to learn another language.

I've used LUA on a number of C/C++ projects and it works very well when it's integrated...

This: http://www.angelcode.com/angelscript/ is another very capapble and easy to use scripting language.